Commit 0bf436a0 authored by bar@mysql.com's avatar bar@mysql.com

Merge mysql.com:/usr/home/bar/mysql-4.1.b13751

into  mysql.com:/usr/home/bar/mysql-5.0.char1
parents ea26f5e2 5df9c6c2
...@@ -1126,3 +1126,8 @@ a ...@@ -1126,3 +1126,8 @@ a
i i
drop table t1,t2; drop table t1,t2;
set names 'latin1';
create table t1 (a varchar(255)) default charset=utf8;
select * from t1 where find_in_set('-1', a);
a
drop table t1;
...@@ -4,6 +4,7 @@ reset master; ...@@ -4,6 +4,7 @@ reset master;
reset slave; reset slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
start slave; start slave;
drop table if exists t1,t2;
CREATE TABLE t1 ( CREATE TABLE t1 (
a int unsigned not null auto_increment primary key, a int unsigned not null auto_increment primary key,
b int unsigned b int unsigned
...@@ -40,3 +41,15 @@ SELECT * FROM t2 ORDER BY a; ...@@ -40,3 +41,15 @@ SELECT * FROM t2 ORDER BY a;
a b a b
1 0 1 0
2 1 2 1
drop table t1,t2;
reset master;
CREATE TABLE t1 ( a INT );
INSERT INTO t1 VALUES (0);
UPDATE t1, (SELECT 3 as b) AS x SET t1.a = x.b;
select * from t1;
a
3
select * from t1;
a
3
drop table t1;
...@@ -851,6 +851,14 @@ insert into t1 values (_utf8 0x5b); ...@@ -851,6 +851,14 @@ insert into t1 values (_utf8 0x5b);
select hex(a) from t1; select hex(a) from t1;
drop table t1; drop table t1;
#
# Bug#13751 find_in_set: Illegal mix of collations
#
set names 'latin1';
create table t1 (a varchar(255)) default charset=utf8;
select * from t1 where find_in_set('-1', a);
drop table t1;
# End of 4.1 tests # End of 4.1 tests
# #
......
...@@ -4,6 +4,10 @@ ...@@ -4,6 +4,10 @@
source include/master-slave.inc; source include/master-slave.inc;
--disable_warnings
drop table if exists t1,t2;
--enable_warnings
CREATE TABLE t1 ( CREATE TABLE t1 (
a int unsigned not null auto_increment primary key, a int unsigned not null auto_increment primary key,
b int unsigned b int unsigned
...@@ -32,4 +36,27 @@ sync_with_master; ...@@ -32,4 +36,27 @@ sync_with_master;
SELECT * FROM t1 ORDER BY a; SELECT * FROM t1 ORDER BY a;
SELECT * FROM t2 ORDER BY a; SELECT * FROM t2 ORDER BY a;
connection master;
drop table t1,t2;
sync_slave_with_master;
#
# BUG#13236 multi-update with subquery & --replicate-ignore-table
#
reset master;
connection master;
CREATE TABLE t1 ( a INT );
INSERT INTO t1 VALUES (0);
UPDATE t1, (SELECT 3 as b) AS x SET t1.a = x.b;
select * from t1;
sync_slave_with_master;
connection slave;
select * from t1;
connection master;
drop table t1;
sync_slave_with_master;
# End of 4.1 tests # End of 4.1 tests
...@@ -2351,7 +2351,7 @@ void Item_func_find_in_set::fix_length_and_dec() ...@@ -2351,7 +2351,7 @@ void Item_func_find_in_set::fix_length_and_dec()
} }
} }
} }
agg_arg_collations_for_comparison(cmp_collation, args, 2); agg_arg_charsets(cmp_collation, args, 2, MY_COLL_CMP_CONV);
} }
static const char separator=','; static const char separator=',';
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment