summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <bar@mysql.com>2005-10-21 16:53:50 +0500
committerunknown <bar@mysql.com>2005-10-21 16:53:50 +0500
commit8c044507ffc3118e5be85b534c1d73a75bdf58b0 (patch)
tree2c5b130b3ccc7b89ebaad3c7288d75f1792c6fc1 /mysql-test
parentf3ee1afe41d8d43ed2d41025434387249828c6aa (diff)
parentcfc78dae98e70175908c156b644071537176a2b3 (diff)
downloadmariadb-git-8c044507ffc3118e5be85b534c1d73a75bdf58b0.tar.gz
Merge mysql.com:/usr/home/bar/mysql-4.1
into mysql.com:/usr/home/bar/mysql-5.0.b12371 mysql-test/t/ctype_utf8.test: Auto merged mysql-test/t/show_check.test: Auto merged ndb/src/kernel/blocks/dbtc/DbtcMain.cpp: Auto merged sql/sql_yacc.yy: Auto merged mysql-test/r/ctype_utf8.result: After merge fix. mysql-test/r/show_check.result: After merge fix. sql/item_strfunc.h: After merge fix. tests/mysql_client_test.c: After merge fix.
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/ctype_utf8.result9
-rw-r--r--mysql-test/r/show_check.result7
-rw-r--r--mysql-test/t/ctype_utf8.test9
-rw-r--r--mysql-test/t/show_check.test13
4 files changed, 38 insertions, 0 deletions
diff --git a/mysql-test/r/ctype_utf8.result b/mysql-test/r/ctype_utf8.result
index 405eff25746..7878fc50b38 100644
--- a/mysql-test/r/ctype_utf8.result
+++ b/mysql-test/r/ctype_utf8.result
@@ -1148,3 +1148,12 @@ set @a:=null;
execute my_stmt using @a;
a b
drop table if exists t1;
+create table t1 (a int);
+insert into t1 values (48),(49),(50);
+set names utf8;
+select distinct char(a) from t1;
+char(a)
+0
+1
+2
+drop table t1;
diff --git a/mysql-test/r/show_check.result b/mysql-test/r/show_check.result
index c143c7f0f29..20f695d9ac0 100644
--- a/mysql-test/r/show_check.result
+++ b/mysql-test/r/show_check.result
@@ -557,3 +557,10 @@ DROP TABLE tyt2;
DROP TABLE urkunde;
SHOW TABLES FROM non_existing_database;
ERROR 42000: Unknown database 'non_existing_database'
+flush tables;
+SHOW TABLE STATUS like 't1';
+Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
+t1 NULL NULL NULL NULL # # # # NULL NULL NULL NULL NULL NULL NULL NULL Incorrect information in file: './test/t1.frm'
+show create table t1;
+ERROR HY000: Incorrect information in file: './test/t1.frm'
+drop table t1;
diff --git a/mysql-test/t/ctype_utf8.test b/mysql-test/t/ctype_utf8.test
index fb6f2f58e35..5670e9efbf9 100644
--- a/mysql-test/t/ctype_utf8.test
+++ b/mysql-test/t/ctype_utf8.test
@@ -859,6 +859,15 @@ create table t1 (a varchar(255)) default charset=utf8;
select * from t1 where find_in_set('-1', a);
drop table t1;
+#
+# Bug#13233: select distinct char(column) fails with utf8
+#
+create table t1 (a int);
+insert into t1 values (48),(49),(50);
+set names utf8;
+select distinct char(a) from t1;
+drop table t1;
+
# End of 4.1 tests
#
diff --git a/mysql-test/t/show_check.test b/mysql-test/t/show_check.test
index b9fc991dc80..89d281a2c58 100644
--- a/mysql-test/t/show_check.test
+++ b/mysql-test/t/show_check.test
@@ -386,6 +386,19 @@ create table t1 (
SHOW CREATE TABLE t1;
DROP TABLE t1;
+# Test for BUG#93: 4.1 protocl crash on corupted frm and SHOW TABLE STATUS
+
+flush tables;
+
+# Create a junk frm file on disk
+system echo "this is a junk file for test" >> var/master-data/test/t1.frm ;
+--replace_column 6 # 7 # 8 # 9 #
+SHOW TABLE STATUS like 't1';
+--error 1033
+show create table t1;
+drop table t1;
+
+
# End of 4.1 tests
#
# BUG 12183 - SHOW OPEN TABLES behavior doesn't match grammar