summaryrefslogtreecommitdiff
path: root/mysql-test/t
diff options
context:
space:
mode:
authorVicențiu Ciorbaru <vicentiu@mariadb.org>2017-09-19 12:06:50 +0300
committerVicențiu Ciorbaru <vicentiu@mariadb.org>2017-09-19 12:06:50 +0300
commitec6042bda097fa53c43caf4a1acc32c5a77f6ed4 (patch)
tree751af6227789bfa916a6de426542a966845c8cd1 /mysql-test/t
parentba0ee91077d9b89296328892aa5d5d293f4e0fb1 (diff)
parentb337a0682943fa7e055380b7859762acf7fb588c (diff)
downloadmariadb-git-ec6042bda097fa53c43caf4a1acc32c5a77f6ed4.tar.gz
Merge branch '10.0' into 10.1
Diffstat (limited to 'mysql-test/t')
-rw-r--r--mysql-test/t/count_distinct.test29
-rw-r--r--mysql-test/t/func_misc.test11
-rw-r--r--mysql-test/t/log_tables-big.test9
-rw-r--r--mysql-test/t/view.test5
4 files changed, 46 insertions, 8 deletions
diff --git a/mysql-test/t/count_distinct.test b/mysql-test/t/count_distinct.test
index a00574b6cba..86045e862e7 100644
--- a/mysql-test/t/count_distinct.test
+++ b/mysql-test/t/count_distinct.test
@@ -121,5 +121,34 @@ drop table t1;
set @@tmp_table_size = default;
#
+# MDEV-13457: Wrong result for aggregate function with distinct clause when the value for
+# tmp_table_size is small
+#
+
+create table t1 (
+a VARCHAR(1020),
+b int
+);
+insert into t1 values
+( 0 , 1 ),
+( 1 , 2 ),
+( 2 , 3 ),
+( 3 , 4 ),
+( 4 , 5 ),
+( 5 , 6 ),
+( 6 , 7 ),
+( 7 , 8 ),
+( 8 , 9 ),
+( 9 , 10 ),
+( 0 , 11 ),
+( 1 , 12 ),
+( 2 , 13 ),
+( 3 , 14 );
+set @@tmp_table_size=1024;
+select count(distinct a) from t1;
+drop table t1;
+set @@tmp_table_size = default;
+
+#
# End of 5.5 tests
#
diff --git a/mysql-test/t/func_misc.test b/mysql-test/t/func_misc.test
index b874700f29d..497ebf44e69 100644
--- a/mysql-test/t/func_misc.test
+++ b/mysql-test/t/func_misc.test
@@ -1107,3 +1107,14 @@ select release_lock('test');
--echo
--echo # -- Done.
--echo
+
+
+--echo #
+--echo # MDEV-13685 Can not replay binary log due to Illegal mix of collations (latin1_swedish_ci,IMPLICIT) and (utf8mb4_general_ci,COERCIBLE) for operation 'concat'
+--echo #
+SET NAMES utf8;
+SELECT COERCIBILITY(NAME_CONST('name','test'));
+SELECT COERCIBILITY(NAME_CONST('name',TIME'00:00:00'));
+SELECT COERCIBILITY(NAME_CONST('name',15));
+SELECT CONCAT(NAME_CONST('name',15),'오');
+SET NAMES latin1;
diff --git a/mysql-test/t/log_tables-big.test b/mysql-test/t/log_tables-big.test
index 8936a163d73..fa8810ecd3b 100644
--- a/mysql-test/t/log_tables-big.test
+++ b/mysql-test/t/log_tables-big.test
@@ -7,6 +7,7 @@
# check that CSV engine was compiled in
--source include/have_csv.inc
+set @log_output.saved = @@global.log_output;
set @@global.log_output = 'TABLE';
connect (con1,localhost,root,,);
@@ -21,13 +22,13 @@ select get_lock('bug27638', 1);
connection con2;
set session long_query_time=1;
select get_lock('bug27638', 2);
-select if (query_time >= '00:00:01', 'OK', 'WRONG') as qt, sql_text from mysql.slow_log
+select if (query_time >= '00:00:01', 'OK', concat('WRONG: ',query_time)) as qt, sql_text from mysql.slow_log
where sql_text = 'select get_lock(\'bug27638\', 2)';
select get_lock('bug27638', 60);
-select if (query_time >= '00:00:59', 'OK', 'WRONG') as qt, sql_text from mysql.slow_log
+select if (query_time >= '00:00:59', 'OK', concat('WRONG: ',query_time)) as qt, sql_text from mysql.slow_log
where sql_text = 'select get_lock(\'bug27638\', 60)';
select get_lock('bug27638', 101);
-select if (query_time >= '00:01:40', 'OK', 'WRONG') as qt, sql_text from mysql.slow_log
+select if (query_time >= '00:01:40', 'OK', concat('WRONG: ',query_time)) as qt, sql_text from mysql.slow_log
where sql_text = 'select get_lock(\'bug27638\', 101)';
connection con1;
select release_lock('bug27638');
@@ -36,4 +37,4 @@ connection default;
disconnect con1;
disconnect con2;
-set @@global.log_output=default;
+set @@global.log_output = @log_output.saved;
diff --git a/mysql-test/t/view.test b/mysql-test/t/view.test
index a1ebc683ed6..d01d922ef3c 100644
--- a/mysql-test/t/view.test
+++ b/mysql-test/t/view.test
@@ -5585,11 +5585,8 @@ drop table t1,t2,t3;
CREATE TABLE t3 (a INT);
CREATE ALGORITHM = MERGE VIEW v1 AS SELECT t2.a FROM t3 AS t1, t3 AS t2;
CREATE ALGORITHM = MERGE VIEW v2 AS SELECT * FROM v1;
-PREPARE stmt FROM 'REPLACE INTO v2 SELECT a FROM t3';
---error ER_VIEW_NO_INSERT_FIELD_LIST
-EXECUTE stmt;
--error ER_VIEW_NO_INSERT_FIELD_LIST
-EXECUTE stmt;
+PREPARE stmt FROM 'REPLACE INTO v2 SELECT a FROM t3';
drop view v1,v2;
drop table t3;