~ubuntu-branches/ubuntu/precise/mysql-5.1/precise

« back to all changes in this revision

Viewing changes to mysql-test/t/mysqlbinlog-cp932.test

  • Committer: Bazaar Package Importer
  • Author(s): Norbert Tretkowski
  • Date: 2010-03-17 14:56:02 UTC
  • Revision ID: james.westby@ubuntu.com-20100317145602-x7e30l1b2sb5s6w6
Tags: upstream-5.1.45
Import upstream version 5.1.45

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# disabled in embedded until tools running is fixed with embedded
 
2
--source include/not_embedded.inc
 
3
 
 
4
-- source include/have_binlog_format_mixed_or_statement.inc
 
5
-- source include/have_cp932.inc
 
6
-- source include/have_log_bin.inc
 
7
 
 
8
RESET MASTER;
 
9
 
 
10
# Bug#16217 (mysql client did not know how not switch its internal charset)
 
11
create table t3 (f text character set utf8);
 
12
create table t4 (f text character set cp932); 
 
13
--exec $MYSQL --default-character-set=utf8 test -e "insert into t3 values(_utf8'ソ')"
 
14
--exec $MYSQL --default-character-set=cp932 test -e "insert into t4 values(_cp932'�\');"
 
15
flush logs;
 
16
rename table t3 to t03, t4 to t04;
 
17
let $MYSQLD_DATADIR= `select @@datadir`;
 
18
--exec $MYSQL_BINLOG --short-form $MYSQLD_DATADIR/master-bin.000001 | $MYSQL --default-character-set=utf8
 
19
# original and recovered data must be equal
 
20
select HEX(f) from t03;
 
21
select HEX(f) from t3;
 
22
select HEX(f) from t04;
 
23
select HEX(f) from t4;
 
24
 
 
25
drop table t3, t4, t03, t04;
 
26
--echo End of 5.0 tests