Details
-
Bug
-
Status: In Review (View Workflow)
-
Major
-
Resolution: Unresolved
-
11.4
-
Q2/2026 Server Development, Q3/2026 Server Maintenance
Description
Run this mtr testcase:
create table t2 ( |
a varchar(100) |
);
|
|
|
set optimizer_trace=1; |
explain
|
select * from t2 where a < '"'; |
|
|
set @trace=(select trace from information_schema.optimizer_trace); |
select json_valid(@trace); |
select @trace; |
|
|
drop table t2; |
You will get:
select json_valid(@trace);
|
json_valid(@trace)
|
0
|
This is because strings are not quoted when they are written into JSON:
"condition_processing": {
|
"condition": "WHERE",
|
"original_condition": "t2.a < '"'",
|
Attachments
Issue Links
- is duplicated by
-
MDEV-39632 Optimizer Trace Produces Invalid JSON for Quoted Table Alias
-
- Closed
-
- relates to
-
MDEV-30354 Optimizer trace does not escape double quotes, produces invalid JSON
-
- Closed
-
-
MDEV-39768 Optimizer trace should use utf8mb4.
-
- Closed
-
-
MDEV-39412 Failed to parse saved optimizer context: error reading ranges value
-
- Closed
-