mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
MDEV-4029 SELECT on information_schema using a subquery locks up the information_schema table due to incorrect mutexes handling
Early evaluation of subqueries in the WHERE conditions on I_S.*_STATUS tables, otherwise the subquery on this same table will try to acquire LOCK_status twice.
This commit is contained in:
8
mysql-test/r/information_schema2.result
Normal file
8
mysql-test/r/information_schema2.result
Normal file
@ -0,0 +1,8 @@
|
||||
select variable_name from information_schema.session_status where variable_name =
|
||||
(select variable_name from information_schema.session_status where variable_name = 'uptime');
|
||||
variable_name
|
||||
UPTIME
|
||||
select variable_name from information_schema.session_variables where variable_name =
|
||||
(select variable_name from information_schema.session_variables where variable_name = 'basedir');
|
||||
variable_name
|
||||
BASEDIR
|
9
mysql-test/t/information_schema2.test
Normal file
9
mysql-test/t/information_schema2.test
Normal file
@ -0,0 +1,9 @@
|
||||
|
||||
#
|
||||
# MDEV-4029 SELECT on information_schema using a subquery locks up the information_schema table due to incorrect mutexes handling
|
||||
#
|
||||
select variable_name from information_schema.session_status where variable_name =
|
||||
(select variable_name from information_schema.session_status where variable_name = 'uptime');
|
||||
select variable_name from information_schema.session_variables where variable_name =
|
||||
(select variable_name from information_schema.session_variables where variable_name = 'basedir');
|
||||
|
Reference in New Issue
Block a user