|
Hi Group,
We are working with a third party to process transactions and receive the
data in JSON.
Recently we received an error using DATA-INTO. Strange thing was it
worked on one system but not on another so we have scheduled to get the
two systems on the same PTF levels.
Anyway the JSON data looks like this;
If account details are provided we get something like this ...
"account": {
"id": 36682,
"name": "HEALTH",
"ref": "45010",
"active": "1",
"type": "INVOICE",
"pin": "",
"prepaid": 0
},
If no account details are present we get ...
"account": [],
We would have expected it to look like:
"account": {},
The third part replied with the following;
We have some stuff like this, things return an object, but if there its no
object its an empty array. When using this in PHP its fine but other
languages it will cause problems. We can queue it up for a fix. Maybe set
it as account: null instead of account: {}
Just wondering on an opinion if you think the null account being provided
as an array is valid or not or how you would address this.
We are using YAJLINTO as the parser.
Don Brown
______________________________________________________________________
This email has been scanned for computer viruses. Although MSD has taken
reasonable precautions to ensure no viruses are present in this email, MSD
cannot accept responsibility for any loss or damage arising from the use of
this email or attachments.
______________________________________________________________________
--
This is the Web Enabling the IBM i (AS/400 and iSeries) (WEB400) mailing
list
To post a message email: WEB400@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/web400.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.