mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Merge remote-tracking branch 'origin/10.2' into 10.3
This commit is contained in:
@ -14,6 +14,14 @@ FROM mysql.slow_log
|
||||
WHERE sql_text NOT LIKE '%debug_dbug%';
|
||||
END
|
||||
$$
|
||||
CREATE PROCEDURE show_slow_log_exclude_ps()
|
||||
BEGIN
|
||||
SELECT CONCAT('[slow] ', sql_text) AS sql_text
|
||||
FROM mysql.slow_log
|
||||
WHERE sql_text NOT LIKE '%debug_dbug%'
|
||||
AND sql_text NOT IN ('Prepare','Close stmt');
|
||||
END
|
||||
$$
|
||||
#
|
||||
# Expect all admin statements in the slow log (ON,DEFAULT)
|
||||
#
|
||||
@ -33,7 +41,7 @@ PREPARE stmt FROM 'ALTER TABLE t4 MODIFY a INT DEFAULT 1';
|
||||
EXECUTE stmt;
|
||||
DEALLOCATE PREPARE stmt;
|
||||
DROP TABLE t4;
|
||||
CALL show_slow_log();
|
||||
CALL show_slow_log_exclude_ps();
|
||||
sql_text
|
||||
[slow] TRUNCATE TABLE mysql.slow_log
|
||||
[slow] CREATE TABLE t1 (a INT)
|
||||
@ -115,7 +123,7 @@ PREPARE stmt FROM 'ALTER TABLE t4 MODIFY a INT DEFAULT 1';
|
||||
EXECUTE stmt;
|
||||
DEALLOCATE PREPARE stmt;
|
||||
DROP TABLE t4;
|
||||
CALL show_slow_log();
|
||||
CALL show_slow_log_exclude_ps();
|
||||
sql_text
|
||||
[slow] TRUNCATE TABLE mysql.slow_log
|
||||
[slow] CREATE TABLE t1 (a INT)
|
||||
@ -140,3 +148,4 @@ SET @@global.slow_query_log= @org_slow_query_log;
|
||||
SET @@global.log_output= @org_log_output;
|
||||
SET @@global.log_slow_admin_statements= @org_log_slow_admin_statements;
|
||||
DROP PROCEDURE show_slow_log;
|
||||
DROP PROCEDURE show_slow_log_exclude_ps;
|
||||
|
Reference in New Issue
Block a user