config root man

Current Path : /home/usr.opt/mysql57/mysql-test/suite/jp/t/

FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64
Upload File :
Current File : //home/usr.opt/mysql57/mysql-test/suite/jp/t/jp_enum_sjis.test

#Server variable option 'lower_case_table_names' sets '0' as default value
#in case sensitive filesystem. Using 'lower_case_table_names=0' in case of
#insensitive filsystem is not allowed.
-- source include/have_case_sensitive_file_system.inc
--source include/have_sjis.inc
--source include/have_innodb.inc
--character_set sjis
--disable_warnings
drop table if exists `sP`;
drop table if exists `sQ`;
drop table if exists `sR`;
drop table if exists `sS`;
drop table if exists `sT`;
drop table if exists `sU`;
drop table if exists `sV`;
drop table if exists `sW`;
drop table if exists `sX`;
drop table if exists t1;
--enable_warnings

#
# Test ENUM values with Japanese characters in sjis encoding
#

SET NAMES sjis;
SET character_set_database = sjis;

CREATE TABLE `sP` (`bP` ENUM('','',''), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = innodb;
CREATE TABLE `sQ` (`bP` ENUM('','',''), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = innodb;
CREATE TABLE `sR` (`bP` ENUM('\','\','\'), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = innodb;
CREATE TABLE `sS` (`bP` ENUM('','',''), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = myisam;
CREATE TABLE `sT` (`bP` ENUM('','',''), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = myisam;
CREATE TABLE `sU` (`bP` ENUM('\','\','\'), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = myisam;
CREATE TABLE `sV` (`bP` ENUM('','',''), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = MEMORY;
CREATE TABLE `sW` (`bP` ENUM('','',''), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = MEMORY;
CREATE TABLE `sX` (`bP` ENUM('\','\','\'), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = MEMORY;

INSERT INTO `sP` VALUES (''),(''),('');
INSERT INTO `sQ` VALUES (''),(''),('');
INSERT INTO `sR` VALUES ('\'),('\'),('\');
INSERT INTO `sS` VALUES (''),(''),('');
INSERT INTO `sT` VALUES (''),(''),('');
INSERT INTO `sU` VALUES ('\'),('\'),('\');
INSERT INTO `sV` VALUES (''),(''),('');
INSERT INTO `sW` VALUES (''),(''),('');
INSERT INTO `sX` VALUES ('\'),('\'),('\');

SELECT * FROM `sP`;
SELECT * FROM `sQ`;
SELECT * FROM `sR`;
SELECT * FROM `sS`;
SELECT * FROM `sT`;
SELECT * FROM `sU`;
SELECT * FROM `sV`;
SELECT * FROM `sW`;
SELECT * FROM `sX`;

SHOW CREATE TABLE `sP`;
SHOW CREATE TABLE `sQ`;
SHOW CREATE TABLE `sR`;
SHOW CREATE TABLE `sS`;
SHOW CREATE TABLE `sT`;
SHOW CREATE TABLE `sU`;
SHOW CREATE TABLE `sV`;
SHOW CREATE TABLE `sW`;
SHOW CREATE TABLE `sX`;

DESC `sP`;
DESC `sQ`;
DESC `sR`;
DESC `sS`;
DESC `sT`;
DESC `sU`;
DESC `sV`;
DESC `sW`;
DESC `sX`;

#
# Test problem with enum values after the colum with  NOT NULL restriction
#

ALTER TABLE `sP` ADD `bQ` CHAR(1) NOT NULL FIRST;
ALTER TABLE `sQ` ADD `bQ` CHAR(1) NOT NULL FIRST;
ALTER TABLE `sR` ADD `bQ` CHAR(1) NOT NULL FIRST;
ALTER TABLE `sS` ADD `bQ` CHAR(1) NOT NULL FIRST;
ALTER TABLE `sT` ADD `bQ` CHAR(1) NOT NULL FIRST;
ALTER TABLE `sU` ADD `bQ` CHAR(1) NOT NULL FIRST;
ALTER TABLE `sV` ADD `bQ` CHAR(1) NOT NULL FIRST;
ALTER TABLE `sW` ADD `bQ` CHAR(1) NOT NULL FIRST;
ALTER TABLE `sX` ADD `bQ` CHAR(1) NOT NULL FIRST;

SHOW CREATE TABLE `sP`;
SHOW CREATE TABLE `sQ`;
SHOW CREATE TABLE `sR`;
SHOW CREATE TABLE `sS`;
SHOW CREATE TABLE `sT`;
SHOW CREATE TABLE `sU`;
SHOW CREATE TABLE `sV`;
SHOW CREATE TABLE `sW`;
SHOW CREATE TABLE `sX`;

#
# Test to distinguish 0x9353 and 0x9373
# Bug#6206 ENUMs are not case sensitive even if declared BINARY
#

CREATE TABLE t1(c1 enum('S','s')) default character set = sjis;
INSERT INTO t1 VALUES('S'),('s');
SELECT * FROM t1 WHERE c1 LIKE 'S';
DROP TABLE t1;

DESC `sP`;
DESC `sQ`;
DESC `sR`;
DESC `sS`;
DESC `sT`;
DESC `sU`;
DESC `sV`;
DESC `sW`;
DESC `sX`;

DROP TABLE `sP`;
DROP TABLE `sQ`;
DROP TABLE `sR`;
DROP TABLE `sS`;
DROP TABLE `sT`;
DROP TABLE `sU`;
DROP TABLE `sV`;
DROP TABLE `sW`;
DROP TABLE `sX`;

Man Man