Details
-
Type:
Bug
-
Status: Closed (View Workflow)
-
Priority:
Critical
-
Resolution: Not a Bug
-
Affects Version/s: 10.7
-
Fix Version/s: N/A
-
Component/s: Parser
-
Labels:None
Description
JSON_EQUALS validates invalid JSON and valid JSON as being equal when using a backslash:
10.7.0 d552e092c9f3e20da078d1b62b976f629f73d3a4 (Debug) |
10.7.0-dbg>SELECT JSON_EQUALS('{"A": 1}', '{"A": 1\}');
|
+--------------------------------------+
|
| JSON_EQUALS('{"A": 1}', '{"A": 1\}') |
|
+--------------------------------------+
|
| 1 |
|
+--------------------------------------+
|
1 row in set (0.001 sec)
|
A simplified version is this (though '{}' is not valid JSON by itself):
10.7.0 d552e092c9f3e20da078d1b62b976f629f73d3a4 (Debug) |
10.7.0-dbg>SELECT JSON_EQUALS('{}', '{\}');
|
+--------------------------+
|
| json_equals('{}', '{\}') |
|
+--------------------------+
|
| 1 |
|
+--------------------------+
|
1 row in set (0.000 sec)
|
Attachments
Issue Links
- is caused by
-
MDEV-23143 Add JSON_EQUALS function to check JSON equality
-
- Closed
-
- relates to
-
MDEV-26679 JSON_VALID validates invalid JSON
-
- Closed
-