summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authortsmith/tim@siva.hindu.god <>2006-10-09 16:16:47 -0600
committertsmith/tim@siva.hindu.god <>2006-10-09 16:16:47 -0600
commitc5b6101c1ba613380ecb47f38f56d33cbcabd9a0 (patch)
treeae73daf7df2355d2007fd20641f3aef7714e7457 /mysql-test
parent5ed44ed09fdb7a2962d31d12fe416ac390bed72d (diff)
parentf5c4d75e8f0fe75950d2b2bfeae482e20520a24b (diff)
downloadmariadb-git-c5b6101c1ba613380ecb47f38f56d33cbcabd9a0.tar.gz
Merge siva.hindu.god:/usr/home/tim/m/bk/b19764/50
into siva.hindu.god:/usr/home/tim/m/bk/tmp/50
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/show_check.result17
-rw-r--r--mysql-test/t/show_check-master.opt1
-rw-r--r--mysql-test/t/show_check.test17
3 files changed, 33 insertions, 2 deletions
diff --git a/mysql-test/r/show_check.result b/mysql-test/r/show_check.result
index 7bdfa78066c..3c90af924e4 100644
--- a/mysql-test/r/show_check.result
+++ b/mysql-test/r/show_check.result
@@ -520,6 +520,7 @@ t1 NULL NULL NULL NULL # # # # NULL NULL NULL NULL NULL NULL NULL NULL Incorrect
show create table t1;
ERROR HY000: Incorrect information in file: './test/t1.frm'
drop table t1;
+End of 4.1 tests
CREATE TABLE txt1(a int);
CREATE TABLE tyt2(a int);
CREATE TABLE urkunde(a int);
@@ -629,3 +630,19 @@ SHOW TABLES FROM no_such_database;
ERROR 42000: Unknown database 'no_such_database'
SHOW COLUMNS FROM no_such_table;
ERROR 42S02: Table 'test.no_such_table' doesn't exist
+flush status;
+show status like 'slow_queries';
+Variable_name Value
+Slow_queries 0
+show tables;
+Tables_in_test
+show status like 'slow_queries';
+Variable_name Value
+Slow_queries 0
+select 1 from information_schema.tables limit 1;
+1
+1
+show status like 'slow_queries';
+Variable_name Value
+Slow_queries 1
+End of 5.0 tests.
diff --git a/mysql-test/t/show_check-master.opt b/mysql-test/t/show_check-master.opt
new file mode 100644
index 00000000000..3eb98fc3d6b
--- /dev/null
+++ b/mysql-test/t/show_check-master.opt
@@ -0,0 +1 @@
+--log-slow-queries --log-long-format --log-queries-not-using-indexes
diff --git a/mysql-test/t/show_check.test b/mysql-test/t/show_check.test
index 65a81545c87..1fc22e38f73 100644
--- a/mysql-test/t/show_check.test
+++ b/mysql-test/t/show_check.test
@@ -400,7 +400,8 @@ show create table t1;
drop table t1;
-# End of 4.1 tests
+--echo End of 4.1 tests
+
#
# BUG 12183 - SHOW OPEN TABLES behavior doesn't match grammar
# First we close all open tables with FLUSH tables and then we open some.
@@ -506,4 +507,16 @@ SHOW TABLES FROM no_such_database;
SHOW COLUMNS FROM no_such_table;
-# End of 5.0 tests.
+#
+# Bug #19764: SHOW commands end up in the slow log as table scans
+#
+flush status;
+show status like 'slow_queries';
+show tables;
+show status like 'slow_queries';
+# Table scan query, to ensure that slow_queries does still get incremented
+# (mysqld is started with --log-queries-not-using-indexes)
+select 1 from information_schema.tables limit 1;
+show status like 'slow_queries';
+
+--echo End of 5.0 tests.