mariadb/mysql-test/suite/jp/t/jp_like_sjis.test
serg@sergbook.mysql.com 77bc68f99d Many files:
Change mode to -rw-rw----
2005-01-07 14:32:05 +02:00

168 lines
8.3 KiB
Text
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

--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 `sPO`;
drop table if exists `sPP`;
drop table if exists `sPQ`;
--enable_warnings
#
# Test LIKE pattern matching using Japanese characters in sjis encoding
#
SET NAMES sjis;
SET character_set_database = sjis;
CREATE TABLE `sP` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = innodb;
CREATE TABLE `sQ` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = innodb;
CREATE TABLE `sR` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = innodb;
CREATE TABLE `sS` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = myisam;
CREATE TABLE `sT` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = myisam;
CREATE TABLE `sU` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = myisam;
CREATE TABLE `sV` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = heap;
CREATE TABLE `sW` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = heap;
CREATE TABLE `sX` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = heap;
CREATE TABLE `sPO` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = bdb;
CREATE TABLE `sPP` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = bdb;
CREATE TABLE `sPQ` (`bP` char(20), INDEX(`bP`)) DEFAULT CHARSET = sjis engine = bdb;
#Load the following data in each table
# jisx0201 hankaku-katakana data
# jisx0208 data
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0201_sjis.dat' INTO TABLE `sP`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0208_sjis.dat' INTO TABLE `sQ`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0208_sjis2.dat' INTO TABLE `sR`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0201_sjis.dat' INTO TABLE `sS`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0208_sjis.dat' INTO TABLE `sT`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0208_sjis2.dat' INTO TABLE `sU`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0201_sjis.dat' INTO TABLE `sV`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0208_sjis.dat' INTO TABLE `sW`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0208_sjis2.dat' INTO TABLE `sX`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0201_sjis.dat' INTO TABLE `sPO`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0208_sjis.dat' INTO TABLE `sPP`;
LOAD DATA LOCAL INFILE 'suite/jp/std_data/jisx0208_sjis2.dat' INTO TABLE `sPQ`;
#InnoDB
SELECT * FROM `sP` WHERE `bP` LIKE ' %';
SELECT * FROM `sP` WHERE `bP` LIKE '% %';
SELECT * FROM `sP` WHERE `bP` LIKE '% ';
SELECT * FROM `sP` WHERE `bP` LIKE 'À%';
SELECT * FROM `sP` WHERE `bP` LIKE '%×Ø%';
SELECT * FROM `sP` WHERE `bP` LIKE '%¿';
SELECT * FROM `sP` WHERE `bP` LIKE '°±²³´µ¶·¸¹º»¼½¾¿%';
SELECT * FROM `sP` WHERE `bP` LIKE '%°±²³´µ¶·¸¹º»¼½¾¿%';
SELECT * FROM `sP` WHERE `bP` LIKE '%°±²³´µ¶·¸¹º»¼½¾¿';
SELECT * FROM `sQ` WHERE `bP` LIKE '<27>@%';
SELECT * FROM `sQ` WHERE `bP` LIKE '%<25>@%';
SELECT * FROM `sQ` WHERE `bP` LIKE '%<25>@';
SELECT * FROM `sQ` WHERE `bP` LIKE '‚Æ%';
SELECT * FROM `sQ` WHERE `bP` LIKE '% %';
SELECT * FROM `sQ` WHERE `bP` LIKE '%‚í';
SELECT * FROM `sQ` WHERE `bP` LIKE '<27>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±%';
SELECT * FROM `sQ` WHERE `bP` LIKE '%<25>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±%';
SELECT * FROM `sQ` WHERE `bP` LIKE '%<25>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±';
SELECT * FROM `sR` WHERE `bP` LIKE 'ƒ\%';
SELECT * FROM `sR` WHERE `bP` LIKE '%\%';
SELECT * FROM `sR` WHERE `bP` LIKE '%ž\';
SELECT * FROM `sR` WHERE `bP` LIKE 'ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\%';
SELECT * FROM `sR` WHERE `bP` LIKE '%ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\%';
SELECT * FROM `sR` WHERE `bP` LIKE '%ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\';
#MyISAM
SELECT * FROM `sS` WHERE `bP` LIKE ' %';
SELECT * FROM `sS` WHERE `bP` LIKE '% %';
SELECT * FROM `sS` WHERE `bP` LIKE '% ';
SELECT * FROM `sS` WHERE `bP` LIKE 'À%';
SELECT * FROM `sS` WHERE `bP` LIKE '%×Ø%';
SELECT * FROM `sS` WHERE `bP` LIKE '%¿';
SELECT * FROM `sS` WHERE `bP` LIKE '°±²³´µ¶·¸¹º»¼½¾¿%';
SELECT * FROM `sS` WHERE `bP` LIKE '%°±²³´µ¶·¸¹º»¼½¾¿%';
SELECT * FROM `sS` WHERE `bP` LIKE '%°±²³´µ¶·¸¹º»¼½¾¿';
SELECT * FROM `sT` WHERE `bP` LIKE '<27>@%';
SELECT * FROM `sT` WHERE `bP` LIKE '%<25>@%';
SELECT * FROM `sT` WHERE `bP` LIKE '%<25>@';
SELECT * FROM `sT` WHERE `bP` LIKE '‚Æ%';
SELECT * FROM `sT` WHERE `bP` LIKE '% %';
SELECT * FROM `sT` WHERE `bP` LIKE '%‚í';
SELECT * FROM `sT` WHERE `bP` LIKE '<27>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±%';
SELECT * FROM `sT` WHERE `bP` LIKE '%<25>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±%';
SELECT * FROM `sT` WHERE `bP` LIKE '%<25>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±';
SELECT * FROM `sU` WHERE `bP` LIKE 'ƒ\%';
SELECT * FROM `sU` WHERE `bP` LIKE '%\%';
SELECT * FROM `sU` WHERE `bP` LIKE '%ž\';
SELECT * FROM `sU` WHERE `bP` LIKE 'ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\%';
SELECT * FROM `sU` WHERE `bP` LIKE '%ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\%';
SELECT * FROM `sU` WHERE `bP` LIKE '%ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\';
#Heap
SELECT * FROM `sV` WHERE `bP` LIKE ' %';
SELECT * FROM `sV` WHERE `bP` LIKE '% %';
SELECT * FROM `sV` WHERE `bP` LIKE '% ';
SELECT * FROM `sV` WHERE `bP` LIKE 'À%';
SELECT * FROM `sV` WHERE `bP` LIKE '%×Ø%';
SELECT * FROM `sV` WHERE `bP` LIKE '%¿';
SELECT * FROM `sV` WHERE `bP` LIKE '°±²³´µ¶·¸¹º»¼½¾¿%';
SELECT * FROM `sV` WHERE `bP` LIKE '%°±²³´µ¶·¸¹º»¼½¾¿%';
SELECT * FROM `sV` WHERE `bP` LIKE '%°±²³´µ¶·¸¹º»¼½¾¿';
SELECT * FROM `sW` WHERE `bP` LIKE '<27>@%';
SELECT * FROM `sW` WHERE `bP` LIKE '%<25>@%';
SELECT * FROM `sW` WHERE `bP` LIKE '%<25>@';
SELECT * FROM `sW` WHERE `bP` LIKE '‚Æ%';
SELECT * FROM `sW` WHERE `bP` LIKE '% %';
SELECT * FROM `sW` WHERE `bP` LIKE '%‚í';
SELECT * FROM `sW` WHERE `bP` LIKE '<27>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±%';
SELECT * FROM `sW` WHERE `bP` LIKE '%<25>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±%';
SELECT * FROM `sW` WHERE `bP` LIKE '%<25>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±';
SELECT * FROM `sX` WHERE `bP` LIKE 'ƒ\%';
SELECT * FROM `sX` WHERE `bP` LIKE '%\%';
SELECT * FROM `sX` WHERE `bP` LIKE '%ž\';
SELECT * FROM `sX` WHERE `bP` LIKE 'ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\%';
SELECT * FROM `sX` WHERE `bP` LIKE '%ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\%';
SELECT * FROM `sX` WHERE `bP` LIKE '%ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\';
#BDB
SELECT * FROM `sPO` WHERE `bP` LIKE ' %';
SELECT * FROM `sPO` WHERE `bP` LIKE '% %';
SELECT * FROM `sPO` WHERE `bP` LIKE '% ';
SELECT * FROM `sPO` WHERE `bP` LIKE 'À%';
SELECT * FROM `sPO` WHERE `bP` LIKE '%×Ø%';
SELECT * FROM `sPO` WHERE `bP` LIKE '%¿';
#SELECT * FROM `sPO` WHERE `bP` LIKE '°±²³´µ¶·¸¹º»¼½¾¿%';
#SELECT * FROM `sPO` WHERE `bP` LIKE '%°±²³´µ¶·¸¹º»¼½¾¿%';
SELECT * FROM `sPO` WHERE `bP` LIKE '%°±²³´µ¶·¸¹º»¼½¾¿';
SELECT * FROM `sPP` WHERE `bP` LIKE '<27>@%';
SELECT * FROM `sPP` WHERE `bP` LIKE '%<25>@%';
SELECT * FROM `sPP` WHERE `bP` LIKE '%<25>@';
SELECT * FROM `sPP` WHERE `bP` LIKE '‚Æ%';
SELECT * FROM `sPP` WHERE `bP` LIKE '% %';
SELECT * FROM `sPP` WHERE `bP` LIKE '%‚í';
#SELECT * FROM `sPP` WHERE `bP` LIKE '<27>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±%';
#SELECT * FROM `sPP` WHERE `bP` LIKE '%<25>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±%';
#SELECT * FROM `sPP` WHERE `bP` LIKE '%<25>EŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±';
SELECT * FROM `sPQ` WHERE `bP` LIKE 'ƒ\%';
SELECT * FROM `sPQ` WHERE `bP` LIKE '%\%';
SELECT * FROM `sPQ` WHERE `bP` LIKE '%ž\';
#SELECT * FROM `sPQ` WHERE `bP` LIKE 'ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\%';
#SELECT * FROM `sPQ` WHERE `bP` LIKE '%ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\%';
#SELECT * FROM `sPQ` WHERE `bP` LIKE '%ƒ\<5C>\•\—\<5C>\‰\Ž\<5C>\“\”\\˜\\\™\š\\œ\<5C>\ž\';
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`;
DROP TABLE `sPO`;
DROP TABLE `sPP`;
DROP TABLE `sPQ`;