Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
69b8dd20
Commit
69b8dd20
authored
May 16, 2024
by
Lena Startseva
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-31933: Make working view-protocol + ps-protocol (running two protocols together)
Fix for v. 11.0
parent
9f7deaab
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
mysql-test/main/opt_trace.test
mysql-test/main/opt_trace.test
+9
-0
mysql-test/main/opt_trace_selectivity.test
mysql-test/main/opt_trace_selectivity.test
+3
-1
No files found.
mysql-test/main/opt_trace.test
View file @
69b8dd20
...
...
@@ -1173,8 +1173,11 @@ insert into t10 select seq, seq, seq from seq_1_to_10000;
explain
format
=
json
select
*
from
t10
where
a
<
3
and
b
!=
5
and
c
<
10
;
set
optimizer_trace
=
'enabled=on'
;
select
*
from
t10
where
a
<
3
and
b
!=
5
and
c
<
10
;
#Enable after fix MDEV-32034
--
disable_view_protocol
select
json_detailed
(
json_extract
(
trace
,
'$**.attaching_conditions_to_tables'
))
as
out1
from
information_schema
.
optimizer_trace
;
--
enable_view_protocol
drop
table
t10
;
--
echo
#
...
...
@@ -1214,8 +1217,11 @@ INSERT INTO t3 SELECT seq, seq from seq_1_to_10;
set
optimizer_trace
=
'enabled=on'
;
explain
partitions
select
*
from
t2
,
t3
where
t2
.
a
in
(
2
,
3
,
4
)
and
t3
.
a
in
(
4
,
5
);
#Enable after fix MDEV-32034
--
disable_view_protocol
select
json_detailed
(
json_extract
(
trace
,
'$**.prune_partitions'
))
as
out1
from
information_schema
.
optimizer_trace
;
--
enable_view_protocol
drop
table
t2
,
t3
;
create
table
t1
(
...
...
@@ -1228,8 +1234,11 @@ create table t1 (
insert
into
t1
values
(
5
),(
15
),(
22
);
explain
select
*
from
t1
where
a
=
28
;
#Enable after fix MDEV-32034
--
disable_view_protocol
select
json_detailed
(
json_extract
(
trace
,
'$**.prune_partitions'
))
as
out1
from
information_schema
.
optimizer_trace
;
--
enable_view_protocol
drop
table
t1
;
set
@@
optimizer_switch
=
@
save_optimizer_switch
;
...
...
mysql-test/main/opt_trace_selectivity.test
View file @
69b8dd20
...
...
@@ -48,7 +48,8 @@ select JSON_DETAILED(JSON_EXTRACT(@trace, '$**.selectivity_for_indexes')) as JS;
--
echo
# Ensure that we only use selectivity from non used index for simple cases
#Enable after fix MDEV-32034
--
disable_view_protocol
select
count
(
*
)
from
t1
where
(
a
=
2
and
b
=
5
);
select
JSON_DETAILED
(
JSON_EXTRACT
(
trace
,
'$**.selectivity_for_indexes'
))
as
JS
from
INFORMATION_SCHEMA
.
OPTIMIZER_TRACE
;
...
...
@@ -81,6 +82,7 @@ from INFORMATION_SCHEMA.OPTIMIZER_TRACE;
select
count
(
*
)
from
t1
where
(
a
between
2
and
3
and
b
between
0
and
100
);
select
JSON_DETAILED
(
JSON_EXTRACT
(
trace
,
'$**.selectivity_for_indexes'
))
as
JS
from
INFORMATION_SCHEMA
.
OPTIMIZER_TRACE
;
--
enable_view_protocol
drop
table
t1
;
set
optimizer_trace
=
'enabled=off'
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment