NetTalk Central
NetTalk Web Server => Web Server - Ask For Help => Topic started by: Thys on March 26, 2018, 12:34:54 AM
-
Hi,
I have a couple of NetWebServiceMethod procedures where the table prefixes are not removed in the resultant JSON, but the settings are correct. This is a sample of the code that the template generates in the BuildResultFields routine:
...
jsonResults.RemovePrefix = true
jsonResults.TagCase = jf:CaseAsIs
jsonResults.CascadeDown()
jsonResults.ExportBlobsWithView = true
...
I thought that the labels in the dictionary would be a possible cause that the prefixes are in the response, but (see attached file) there is nothing strange about the table definition. Below is an example of the response:
{
"dbStaff_response": {
"queue": [
{
"STFF:USERID": "AB",
"STFF:INITIALS": "AB",
"STFF:SURNAME": "Botha",
"STFF:NAME": "Andrea",
"STFF:TELNOWORK": "12650",
"STFF:TELNOHOME": "(010)430 7873",
"STFF:TELNOCELL": "089 577-2539",
"STFF:ADDTELCONTACT": "(010) 312-6458",
"STFF:PARENTUSERID": "",
"STFF:EMAIL": "m@m.com",
"STFF:ALTERNATIVEID": ""
}
]
}
}
Any ideas on how to fix it, without overriding each column's label?
Thys
-
my guess is you're using a not-quite-recent build of jFiles. From the jFiles release notes;
>> 1.60 : Change: MAxPrefixLengthInJSON default value set to 5, up from 4 (includes colon).
Also you may not be up to date with NetTalk, from the release notes there
>> 10.16 : Change: WebServiceMethod: uses file prefix length to set MaxPrefixLengthInJson.
cheers
Bruce
-
I'm not up to date with jFiles - will get that done. With NT I'm on the latest.
Thanks