Examples: JSON_CHECK

Teradata Vantageā„¢ JSON Data Type

brand
Software
Teradata Vantage
prodname
Teradata Database
Teradata Vantage NewSQL Engine
vrm_release
16.20
category
Programming Reference
featnum
B035-1150-162K

Valid JSON String Argument

The string passed to JSON_CHECK in this query has valid JSON syntax; therefore, the function returns 'OK'.
SELECT JSON_CHECK('{"name" : "Cameron", "age" : 24, "schools" : [ {"name" : "Lake", "type" : "elementary"}, {"name" : "Madison", "type" : "middle"}, {"name" : "Rancho", "type" : "high"}, {"name" : "UCI", "type" : "college"} ], "job" : "programmer" }');

Invalid JSON String Argument

The string passed to JSON_CHECK in this query is not valid JSON syntax; therefore, the function returns the error message: INVALID: Expected something like whitespace or '"' between ',' and the end of the string.

SELECT JSON_Check('{"name" : "Cameron",');