Components All New MacOS Windows Linux iOS
Examples Mac & Win Server Client Guides Statistic FMM Blog Deprecated Old


Queries entry from array with given index.

Component Version macOS Windows Linux Server iOS SDK
JSON 2.7 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "JSON.GetArrayItem"; json; index { ; Flags } )   More


Parameter Description Example Flags
json A JSON text or reference. "[1,2,3]"
index The index of the array element. 0
Flags Pass various flags.
0 returns as JSON text.
1 returns as JSON reference number.
2 returns as value.
Default is 0.
0 Optional


Returns JSON code.


Queries entry from array with given index.
Index is zero based.


Create array and pick second item:

j = MBS( "JSON.CreateDoubleArray"; 1; 2; 3);
r = MBS( "JSON.GetArrayItem"; j; 1 )

See also

Release notes

Example Databases

Blog Entries

This function checks for a license.

Created 18th August 2014, last changed 27th September 2020

JSON.Format - JSON.GetArrayItems