Details
-
Bug
-
Status: Confirmed (View Workflow)
-
Major
-
Resolution: Unresolved
-
11.4, 11.8, 12.3, 13.1
Description
Hi,
I found that the JSON_SCHEMA_VALID function returns true on the JSON data that violate the structure and unique requirement.
SET @schema = '{"type":"object","required":["str1","str1"]}'; |
SELECT JSON_SCHEMA_VALID(@schema, '{"str1":"abc"}'); -- 1, expected 0 as these two string should be identical |
 |
SET @schema = '{"type":"object","dependentRequired":{"a":["b","b"]}}'; |
SELECT JSON_SCHEMA_VALID(@schema, '{"a":1,"b":2}'); -- 1, expected 0 as child should be an array |