JSON get_num validation

Started by Rob, October 23, 2025, 12:24:34 PM

Previous topic - Next topic

Rob

How does GET_NUM(KEY$,validation) work if validation is on?

Do you get an ERROR 11 for a missing key?

Aaron Woodhouse

Hi Rob!

Using the get_num function normally without the no_validation flag will return an error 11 if the key doesn't exist. It does some checks within the object's keys to make sure your provided key will work.

If you use the no_validation flag, it will skip this initial key check, and instead return an error 23 since it can't actually find the value.

It will return an error either way, but the key validator would tell you the issue is due to the key, not that there is no value.
Software Developer
PVX Plus Technologies LTD.