META TOPICPARENT |
name="FullAPIList" |
.JSON PARSE
This subroutine parses and imports a JSON string (Added in 6.2.0).
Usage:
PASS <JSON String> FIELD SHARE? N
PASS <Mode> FIELD SHARE? N
GOSUB --- .JSON PARSE
* Check for errors
IF --- .JSON PARSE NE
Description:
This subroutine processes a JSON string and imports it.
<JSON String> is an alpha field which holds the JSON data. It can be raw or Unicode.
<Mode> can be "SMALL", "MEDIUM", or "LARGE". The value for the mode specifies what file the subroutine uses to import the parsed JSON data into. If you set the mode to SMALL, the result will be written to --- JSONUS memory-related file, if you set the mode to MEDIUM, the result will be written to --- JSONUM memory-related file, and if you set the mode to LARGE, the result will be written to --- JSONUL disk-related file. The difference between these files is the size of the value field.
Please note that setting mode to SMALL gives you the best performance, and setting mode to LARGE gives you the worst performance. So, if you are certain that the value for each attribute doesn't exceed 256 character, use Mode=SMALL, if the value doesn't exceed 32000 characters, use Mode=MEDIUM, otherwise use Mode=LARGE.
To parse a JSON file use .JSON PARSE FILE subroutine.
Comments:
Read what other users have said about this page or add your own comments.
|