mariadb/mysql-test/r/character_set_connection_func.result
Horst Hunger a5e248d402 Final fix for bug#38349: Did the changes due to the 2 reviews.
- Updated slow_query_log_file_basic and general_log_file basis instead of the func version as
the func version run good but the basic versions fail.
- Sent innodb.test to dev@innodb.com.
- variables.test has differences probably due to a bug in mtr or in the SET statement (see bug#39369).
- general_log_file_basic.test and slow_query_log_file_bsaic.test have differences, which might be 
produced by the new mtr (see bug#38124).
2008-09-10 12:50:39 +02:00

56 lines
2 KiB
Text

'#--------------------FN_DYNVARS_011_01-------------------------#'
SET @global_character_set_connection = @@global.character_set_connection;
SET @session_character_set_connection = @@session.character_set_connection;
SET @session_character_set_client = @@session.character_set_client;
SET @session_character_set_results = @@session.character_set_results;
SET @@global.character_set_connection = utf8;
'connect (con1,localhost,root,,,,)'
'connection con1'
SELECT @@global.character_set_connection;
@@global.character_set_connection
utf8
SELECT @@session.character_set_connection;
@@session.character_set_connection
utf8
'#--------------------FN_DYNVARS_011_02-------------------------#'
'connection default'
DROP TABLE IF EXISTS t1;
CREATE TABLE t1(b CHAR(40) CHARACTER SET utf8);
'--verify that character_set_connection converts character_set_client--'
SET @@session.character_set_client = utf8;
SET @@session.character_set_results = utf8;
SET @@session.character_set_connection = latin1;
SELECT 'ЁЂЃЄ' AS utf_text;
utf_text
????
SET @@session.character_set_connection = utf8;
SELECT 'ЁЂЃЄ' AS utf_text;
utf_text
ЁЂЃЄ
'---now inserting utf8 string with different character_set_connection--'
SET @@session.character_set_connection = ascii;
INSERT INTO t1 VALUES('ЁЂЃЄ');
SELECT * FROM t1;
b
????
TRUNCATE TABLE t1;
'--now client & results charset in latin1 & connection charset in ascii-'
SET @@session.character_set_connection = ascii;
SET @@session.character_set_client = latin1;
SET @@session.character_set_results = latin1;
INSERT INTO t1 VALUES('ЁЂЃЄ');
SELECT * FROM t1;
b
????????
TRUNCATE TABLE t1;
SET NAMES utf8;
INSERT INTO t1 VALUES('ЁЂЃЄ');
SELECT * FROM t1;
b
ЁЂЃЄ
TRUNCATE TABLE t1;
SET @@global.character_set_connection = @global_character_set_connection;
SET @@session.character_set_connection = @session_character_set_connection;
SET @@session.character_set_client = @session_character_set_client;
SET @@session.character_set_results = @session_character_set_results;
DROP TABLE t1;