Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
12.3.2
-
None
-
None
-
MariaDB Server 12.3.2, Windows x64
-
JSON Schema Draft 2020-12 says an instance validates successfully when uniqueItems is false, regardless of whether the array contains duplicates. MariaDB returns false for a valid instance.
Description
Description
JSON Schema Draft 2020-12 says an instance validates successfully when uniqueItems is false, regardless of whether the array contains duplicates. MariaDB returns false for a valid instance.
How to repeat
SELECT VERSION();
SELECT JSON_SCHEMA_VALID('
{"uniqueItems":false}', '[1,1]') AS duplicate_items;
SELECT JSON_SCHEMA_VALID('{}', '[1,1]') AS omitted_keyword_control;
SELECT JSON_SCHEMA_VALID('
', '[1,1]') AS true_keyword_control;
Actual result
MariaDB returns 0, 1, 0.
Expected result
The results should be 1, 1, 0. Duplicate strings and duplicate objects are also incorrectly rejected with uniqueItems:false.