jp_select_sjis.test 3.18 KB
--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 Displaying Japanese charact 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
# jisx0212 supplemental character 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`;
SELECT * FROM `sQ`;
SELECT * FROM `sR`;
#MyISAM
SELECT * FROM `sS`;
SELECT * FROM `sT`;
SELECT * FROM `sU`;
#Heap
SELECT * FROM `sV`;
SELECT * FROM `sW`;
SELECT * FROM `sX`;
#BDB
SELECT * FROM `sPO`;
SELECT * FROM `sPP`;
SELECT * FROM `sPQ`;

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`;