提交 d0cab790 编写于 作者: H Heikki Linnakangas

Remove unused regression test files.

euc_* and mule_internal test cases were identical to the ones in
src/test/mb. sql_ascii didn't exist elsewhere, but has been broken since
2001, and doesn't seem very interesting anyway. drop.sql hasn't been used
since 2000, when regress.sh was removed.
上级 f472012a
drop table 计算机术语;
ERROR: Relation '计算机术语' does not exist
create table 计算机术语(术语 text, 分类号 varchar, 备注1A char(16));
create index 计算机术语index1 on 计算机术语 using btree(术语);
create index 计算机术语index2 on 计算机术语 using btree(分类号);
insert into 计算机术语 values('电脑显示屏','机A01上');
insert into 计算机术语 values('电脑图形','分B01中');
insert into 计算机术语 values('电脑程序员','人Z01下');
vacuum 计算机术语;
select * from 计算机术语;
术语 | 分类号 | 备注1a
------------+---------+--------
电脑显示屏 | 机A01上 |
电脑图形 | 分B01中 |
电脑程序员 | 人Z01下 |
(3 rows)
select * from 计算机术语 where 分类号 = '人Z01下';
术语 | 分类号 | 备注1a
------------+---------+--------
电脑程序员 | 人Z01下 |
(1 row)
select * from 计算机术语 where 分类号 ~* '人z01下';
术语 | 分类号 | 备注1a
------------+---------+--------
电脑程序员 | 人Z01下 |
(1 row)
select * from 计算机术语 where 分类号 like '_Z01_';
术语 | 分类号 | 备注1a
------------+---------+--------
电脑程序员 | 人Z01下 |
(1 row)
select * from 计算机术语 where 分类号 like '_Z%';
术语 | 分类号 | 备注1a
------------+---------+--------
电脑程序员 | 人Z01下 |
(1 row)
select * from 计算机术语 where 术语 ~ '电脑[显图]';
术语 | 分类号 | 备注1a
------------+---------+--------
电脑显示屏 | 机A01上 |
电脑图形 | 分B01中 |
(2 rows)
select * from 计算机术语 where 术语 ~* '电脑[显图]';
术语 | 分类号 | 备注1a
------------+---------+--------
电脑显示屏 | 机A01上 |
电脑图形 | 分B01中 |
(2 rows)
select *,character_length(术语) from 计算机术语;
术语 | 分类号 | 备注1a | char_length
------------+---------+--------+-------------
电脑显示屏 | 机A01上 | | 5
电脑图形 | 分B01中 | | 4
电脑程序员 | 人Z01下 | | 5
(3 rows)
select *,octet_length(术语) from 计算机术语;
术语 | 分类号 | 备注1a | octet_length
------------+---------+--------+--------------
电脑显示屏 | 机A01上 | | 10
电脑图形 | 分B01中 | | 8
电脑程序员 | 人Z01下 | | 10
(3 rows)
select *,position('显' in 术语) from 计算机术语;
术语 | 分类号 | 备注1a | strpos
------------+---------+--------+--------
电脑显示屏 | 机A01上 | | 3
电脑图形 | 分B01中 | | 0
电脑程序员 | 人Z01下 | | 0
(3 rows)
select *,substring(术语 from 3 for 4) from 计算机术语;
术语 | 分类号 | 备注1a | substr
------------+---------+--------+--------
电脑显示屏 | 机A01上 | | 显示屏
电脑图形 | 分B01中 | | 图形
电脑程序员 | 人Z01下 | | 程序员
(3 rows)
drop table 計算機用語;
ERROR: table "計算機用語" is nonexistent
create table 計算機用語 (用語 text, 分類コード varchar, 備考1Aだよ char(16));
create index 計算機用語index1 on 計算機用語 using btree (用語);
create index 計算機用語index2 on 計算機用語 using hash (分類コード);
insert into 計算機用語 values('コンピュータディスプレイ','機A01上');
insert into 計算機用語 values('コンピュータグラフィックス','分B10中');
insert into 計算機用語 values('コンピュータプログラマー','人Z01下');
vacuum 計算機用語;
select * from 計算機用語;
用語 | 分類コード | 備考1aだよ
----------------------------+------------+------------
コンピュータディスプレイ | 機A01上 |
コンピュータグラフィックス | 分B10中 |
コンピュータプログラマー | 人Z01下 |
(3 rows)
select * from 計算機用語 where 分類コード = '人Z01下';
用語 | 分類コード | 備考1aだよ
--------------------------+------------+------------
コンピュータプログラマー | 人Z01下 |
(1 row)
select * from 計算機用語 where 分類コード ~* '人z01下';
用語 | 分類コード | 備考1aだよ
--------------------------+------------+------------
コンピュータプログラマー | 人Z01下 |
(1 row)
select * from 計算機用語 where 分類コード like '_Z01_';
用語 | 分類コード | 備考1aだよ
--------------------------+------------+------------
コンピュータプログラマー | 人Z01下 |
(1 row)
select * from 計算機用語 where 分類コード like '_Z%';
用語 | 分類コード | 備考1aだよ
--------------------------+------------+------------
コンピュータプログラマー | 人Z01下 |
(1 row)
select * from 計算機用語 where 用語 ~ 'コンピュータ[デグ]';
用語 | 分類コード | 備考1aだよ
----------------------------+------------+------------
コンピュータディスプレイ | 機A01上 |
コンピュータグラフィックス | 分B10中 |
(2 rows)
select * from 計算機用語 where 用語 ~* 'コンピュータ[デグ]';
用語 | 分類コード | 備考1aだよ
----------------------------+------------+------------
コンピュータディスプレイ | 機A01上 |
コンピュータグラフィックス | 分B10中 |
(2 rows)
select *,character_length(用語) from 計算機用語;
用語 | 分類コード | 備考1aだよ | char_length
----------------------------+------------+------------+-------------
コンピュータディスプレイ | 機A01上 | | 12
コンピュータグラフィックス | 分B10中 | | 13
コンピュータプログラマー | 人Z01下 | | 12
(3 rows)
select *,octet_length(用語) from 計算機用語;
用語 | 分類コード | 備考1aだよ | octet_length
----------------------------+------------+------------+--------------
コンピュータディスプレイ | 機A01上 | | 24
コンピュータグラフィックス | 分B10中 | | 26
コンピュータプログラマー | 人Z01下 | | 24
(3 rows)
select *,position('デ' in 用語) from 計算機用語;
用語 | 分類コード | 備考1aだよ | strpos
----------------------------+------------+------------+--------
コンピュータディスプレイ | 機A01上 | | 7
コンピュータグラフィックス | 分B10中 | | 0
コンピュータプログラマー | 人Z01下 | | 0
(3 rows)
select *,substring(用語 from 10 for 4) from 計算機用語;
用語 | 分類コード | 備考1aだよ | substr
----------------------------+------------+------------+----------
コンピュータディスプレイ | 機A01上 | | プレイ
コンピュータグラフィックス | 分B10中 | | ィックス
コンピュータプログラマー | 人Z01下 | | ラマー
(3 rows)
drop table 計算機용어;
ERROR: Relation '計算機용어' does not exist
create table 計算機용어 (용어 text, 分類코드 varchar, 비고1A라구 char(16));
create index 計算機용어index1 on 計算機용어 using btree (용어);
create index 計算機용어index2 on 計算機용어 using hash (分類코드);
insert into 計算機용어 values('컴퓨터디스플레이', '機A01上');
insert into 計算機용어 values('컴퓨터그래픽스', '分B10中');
insert into 計算機용어 values('컴퓨터프로그래머', '人Z01下');
vacuum 計算機용어;
select * from 計算機용어;
용어 | 分類코드 | 비고1a라구
------------------+----------+------------
컴퓨터디스플레이 | 機A01上 |
컴퓨터그래픽스 | 分B10中 |
컴퓨터프로그래머 | 人Z01下 |
(3 rows)
select * from 計算機용어 where 分類코드 = '人Z01下';
용어 | 分類코드 | 비고1a라구
------------------+----------+------------
컴퓨터프로그래머 | 人Z01下 |
(1 row)
select * from 計算機용어 where 分類코드 ~* '人z01下';
용어 | 分類코드 | 비고1a라구
------------------+----------+------------
컴퓨터프로그래머 | 人Z01下 |
(1 row)
select * from 計算機용어 where 分類코드 like '_Z01_';
용어 | 分類코드 | 비고1a라구
------------------+----------+------------
컴퓨터프로그래머 | 人Z01下 |
(1 row)
select * from 計算機용어 where 分類코드 like '_Z%';
용어 | 分類코드 | 비고1a라구
------------------+----------+------------
컴퓨터프로그래머 | 人Z01下 |
(1 row)
select * from 計算機용어 where 용어 ~ '컴퓨터[디그]';
용어 | 分類코드 | 비고1a라구
------------------+----------+------------
컴퓨터디스플레이 | 機A01上 |
컴퓨터그래픽스 | 分B10中 |
(2 rows)
select * from 計算機용어 where 용어 ~* '컴퓨터[디그]';
용어 | 分類코드 | 비고1a라구
------------------+----------+------------
컴퓨터디스플레이 | 機A01上 |
컴퓨터그래픽스 | 分B10中 |
(2 rows)
select *,character_length(용어) from 計算機용어;
용어 | 分類코드 | 비고1a라구 | char_length
------------------+----------+------------+-------------
컴퓨터디스플레이 | 機A01上 | | 8
컴퓨터그래픽스 | 分B10中 | | 7
컴퓨터프로그래머 | 人Z01下 | | 8
(3 rows)
select *,octet_length(용어) from 計算機용어;
용어 | 分類코드 | 비고1a라구 | octet_length
------------------+----------+------------+--------------
컴퓨터디스플레이 | 機A01上 | | 16
컴퓨터그래픽스 | 分B10中 | | 14
컴퓨터프로그래머 | 人Z01下 | | 16
(3 rows)
select *,position('디' in 용어) from 計算機용어;
용어 | 分類코드 | 비고1a라구 | strpos
------------------+----------+------------+--------
컴퓨터디스플레이 | 機A01上 | | 4
컴퓨터그래픽스 | 分B10中 | | 0
컴퓨터프로그래머 | 人Z01下 | | 0
(3 rows)
select *,substring(용어 from 3 for 4) from 計算機용어;
용어 | 分類코드 | 비고1a라구 | substr
------------------+----------+------------+----------
컴퓨터디스플레이 | 機A01上 | | 터디스플
컴퓨터그래픽스 | 分B10中 | | 터그래픽
컴퓨터프로그래머 | 人Z01下 | | 터프로그
(3 rows)
drop table 燹俑骜砧;
ERROR: Relation '燹俑骜砧' does not exist
create table 燹俑骜砧 (如淦杀 text, 狞瞥婉螭 varchar, 氢蛇 varchar(16));
create index 燹俑骜砧index1 on 燹俑骜砧 using btree (如淦杀);
create index 燹俑骜砧index2 on 燹俑骜砧 using hash (狞瞥婉螭);
insert into 燹俑骜砧 values ('缳妾淦', '绠绠绎世', '啤A01念');
insert into 燹俑骜砧 values ('犒葸淦', '芈溷却宇狞瞥', '你B10你');
insert into 燹俑骜砧 values ('螫悖淦', '印汤洗枪却宇狞瞥', '仨Z01摩');
vacuum 燹俑骜砧;
select * from 燹俑骜砧;
如淦杀 | 狞瞥婉螭 | 氢蛇
--------+------------------+---------
缳妾淦 | 绠绠绎世 | 啤A01念
犒葸淦 | 芈溷却宇狞瞥 | 你B10你
螫悖淦 | 印汤洗枪却宇狞瞥 | 仨Z01摩
(3 rows)
select * from 燹俑骜砧 where 氢蛇 = '仨Z01摩';
如淦杀 | 狞瞥婉螭 | 氢蛇
--------+------------------+---------
螫悖淦 | 印汤洗枪却宇狞瞥 | 仨Z01摩
(1 row)
select * from 燹俑骜砧 where 氢蛇 ~* '仨z01摩';
如淦杀 | 狞瞥婉螭 | 氢蛇
--------+------------------+---------
螫悖淦 | 印汤洗枪却宇狞瞥 | 仨Z01摩
(1 row)
select * from 燹俑骜砧 where 氢蛇 like '_Z01_';
如淦杀 | 狞瞥婉螭 | 氢蛇
--------+------------------+---------
螫悖淦 | 印汤洗枪却宇狞瞥 | 仨Z01摩
(1 row)
select * from 燹俑骜砧 where 氢蛇 like '_Z%';
如淦杀 | 狞瞥婉螭 | 氢蛇
--------+------------------+---------
螫悖淦 | 印汤洗枪却宇狞瞥 | 仨Z01摩
(1 row)
select * from 燹俑骜砧 where 狞瞥婉螭 ~ '绠绠绎[凫卮世]';
如淦杀 | 狞瞥婉螭 | 氢蛇
--------+----------+---------
缳妾淦 | 绠绠绎世 | 啤A01念
(1 row)
select * from 燹俑骜砧 where 狞瞥婉螭 ~* '绠绠绎[凫卮世]';
如淦杀 | 狞瞥婉螭 | 氢蛇
--------+----------+---------
缳妾淦 | 绠绠绎世 | 啤A01念
(1 row)
select *, character_length(如淦杀) from 燹俑骜砧;
如淦杀 | 狞瞥婉螭 | 氢蛇 | char_length
--------+------------------+---------+-------------
缳妾淦 | 绠绠绎世 | 啤A01念 | 3
犒葸淦 | 芈溷却宇狞瞥 | 你B10你 | 3
螫悖淦 | 印汤洗枪却宇狞瞥 | 仨Z01摩 | 3
(3 rows)
select *, octet_length(如淦杀) from 燹俑骜砧;
如淦杀 | 狞瞥婉螭 | 氢蛇 | octet_length
--------+------------------+---------+--------------
缳妾淦 | 绠绠绎世 | 啤A01念 | 6
犒葸淦 | 芈溷却宇狞瞥 | 你B10你 | 6
螫悖淦 | 印汤洗枪却宇狞瞥 | 仨Z01摩 | 6
(3 rows)
select *, position('却宇' in 狞瞥婉螭) from 燹俑骜砧;
如淦杀 | 狞瞥婉螭 | 氢蛇 | strpos
--------+------------------+---------+--------
缳妾淦 | 绠绠绎世 | 啤A01念 | 0
犒葸淦 | 芈溷却宇狞瞥 | 你B10你 | 3
螫悖淦 | 印汤洗枪却宇狞瞥 | 仨Z01摩 | 5
(3 rows)
select *, substring(狞瞥婉螭 from 3 for 6 ) from 燹俑骜砧;
如淦杀 | 狞瞥婉螭 | 氢蛇 | substr
--------+------------------+---------+--------------
缳妾淦 | 绠绠绎世 | 啤A01念 | 绎世
犒葸淦 | 芈溷却宇狞瞥 | 你B10你 | 却宇狞瞥
螫悖淦 | 印汤洗枪却宇狞瞥 | 仨Z01摩 | 洗枪却宇狞瞥
(3 rows)
drop table גђ;
ERROR: Relation 'גђ' does not exist
create table גђ (ђ text, ʬ varchar, 1A char(16));
create index גђindex1 on גђ using btree (ђ);
create index גђindex2 on גђ using hash (ʬ);
insert into גђ values('Ԓ咡ǒג쒥','A01');
insert into גђ values('Ԓ咡钥ՒÒ','ʬB10');
insert into גђ values('Ԓ咡ג풥钥ޒ','Z01');
vacuum גђ;
select * from גђ;
ђ | ʬ | 1a
-----------------------------------------+-----------------+----------------
Ԓ咡ǒג쒥 | A01 |
Ԓ咡钥ՒÒ | ʬB10 |
Ԓ咡ג풥钥ޒ | Z01 |
(3 rows)
select * from גђ where ʬ = 'Z01';
ђ | ʬ | 1a
--------------------------------------+-----------------+----------------
Ԓ咡ג풥钥ޒ | Z01 |
(1 row)
select * from גђ where ʬ ~* 'z01';
ђ | ʬ | 1a
--------------------------------------+-----------------+----------------
Ԓ咡ג풥钥ޒ | Z01 |
(1 row)
select * from גђ where ʬ like '_Z01_';
ђ | ʬ | 1a
--------------------------------------+-----------------+----------------
Ԓ咡ג풥钥ޒ | Z01 |
(1 row)
select * from גђ where ʬ like '_Z%';
ђ | ʬ | 1a
--------------------------------------+-----------------+----------------
Ԓ咡ג풥钥ޒ | Z01 |
(1 row)
select * from גђ where ђ ~ 'Ԓ咡[ǒ]';
ђ | ʬ | 1a
-----------------------------------------+-----------------+----------------
Ԓ咡ǒג쒥 | A01 |
Ԓ咡钥ՒÒ | ʬB10 |
(2 rows)
select * from גђ where ђ ~* 'Ԓ咡[ǒ]';
ђ | ʬ | 1a
-----------------------------------------+-----------------+----------------
Ԓ咡ǒג쒥 | A01 |
Ԓ咡钥ՒÒ | ʬB10 |
(2 rows)
select *,character_length(ђ) from גђ;
ђ | ʬ | 1a | char_length
-----------------------------------------+-----------------+----------------+-------------
Ԓ咡ǒג쒥 | A01 | | 12
Ԓ咡钥ՒÒ | ʬB10 | | 13
Ԓ咡ג풥钥ޒ | Z01 | | 12
(3 rows)
select *,octet_length(ђ) from גђ;
ђ | ʬ | 1a | octet_length
-----------------------------------------+-----------------+----------------+--------------
Ԓ咡ǒג쒥 | A01 | | 36
Ԓ咡钥ՒÒ | ʬB10 | | 39
Ԓ咡ג풥钥ޒ | Z01 | | 36
(3 rows)
select *,position('' in ђ) from גђ;
ђ | ʬ | 1a | strpos
-----------------------------------------+-----------------+----------------+--------
Ԓ咡ǒג쒥 | A01 | | 7
Ԓ咡钥ՒÒ | ʬB10 | | 0
Ԓ咡ג풥钥ޒ | Z01 | | 0
(3 rows)
select *,substring(ђ from 10 for 4) from גђ;
ђ | ʬ | 1a | substr
-----------------------------------------+-----------------+----------------+--------------
Ԓ咡ǒג쒥 | A01 | | ג쒥
Ԓ咡钥ՒÒ | ʬB10 | | Ò
Ԓ咡ג풥钥ޒ | Z01 | | 钥ޒ
(3 rows)
drop table Ƒ㑻;
ERROR: Relation 'Ƒ㑻' does not exist
create table Ƒ㑻( text, ֑ varchar, ע1A char(16));
create index Ƒ㑻index1 on Ƒ㑻 using btree();
create index Ƒ㑻index2 on Ƒ㑻 using btree(֑);
insert into Ƒ㑻 values('ԑԑʾ','A01');
insert into Ƒ㑻 values('ԑͼ','B01');
insert into Ƒ㑻 values('ԑ̑Ա','Z01');
vacuum Ƒ㑻;
select * from Ƒ㑻;
| ֑ | ע1a
-----------------+-----------+----------
ԑԑʾ | A01 |
ԑͼ | B01 |
ԑ̑Ա | Z01 |
(3 rows)
select * from Ƒ㑻 where ֑ = 'Z01';
| ֑ | ע1a
-----------------+-----------+----------
ԑ̑Ա | Z01 |
(1 row)
select * from Ƒ㑻 where ֑ ~* 'z01';
| ֑ | ע1a
-----------------+-----------+----------
ԑ̑Ա | Z01 |
(1 row)
select * from Ƒ㑻 where ֑ like '_Z01_';
| ֑ | ע1a
-----------------+-----------+----------
ԑ̑Ա | Z01 |
(1 row)
select * from Ƒ㑻 where ֑ like '_Z%';
| ֑ | ע1a
-----------------+-----------+----------
ԑ̑Ա | Z01 |
(1 row)
select * from Ƒ㑻 where ~ '[ԑͼ]';
| ֑ | ע1a
-----------------+-----------+----------
ԑԑʾ | A01 |
ԑͼ | B01 |
(2 rows)
select * from Ƒ㑻 where ~* '[ԑͼ]';
| ֑ | ע1a
-----------------+-----------+----------
ԑԑʾ | A01 |
ԑͼ | B01 |
(2 rows)
select *,character_length() from Ƒ㑻;
| ֑ | ע1a | char_length
-----------------+-----------+----------+-------------
ԑԑʾ | A01 | | 5
ԑͼ | B01 | | 4
ԑ̑Ա | Z01 | | 5
(3 rows)
select *,octet_length() from Ƒ㑻;
| ֑ | ע1a | octet_length
-----------------+-----------+----------+--------------
ԑԑʾ | A01 | | 15
ԑͼ | B01 | | 12
ԑ̑Ա | Z01 | | 15
(3 rows)
select *,position('' in ) from Ƒ㑻;
| ֑ | ע1a | strpos
-----------------+-----------+----------+--------
ԑԑʾ | A01 | | 3
ԑͼ | B01 | | 0
ԑ̑Ա | Z01 | | 0
(3 rows)
select *,substring( from 3 for 4) from Ƒ㑻;
| ֑ | ע1a | substr
-----------------+-----------+----------+-----------
ԑԑʾ | A01 | | ԑʾ
ԑͼ | B01 | | ͼ
ԑ̑Ա | Z01 | | ̑Ա
(3 rows)
drop table ͪߩѦ듾;
ERROR: Relation 'ͪߩѦ듾' does not exist
create table ͪߩѦ듾 (듾 text, “׾ړ varchar, 1A󓱸 char(16));
create index ͪߩѦ듾index1 on ͪߩѦ듾 using btree (듾);
create index ͪߩѦ듾index2 on ͪߩѦ듾 using hash (“׾ړ);
insert into ͪߩѦ듾 values('ēǻ͓𓽺Ó', 'ѦA01߾');
insert into ͪߩѦ듾 values('ēǻ͓דȓ', 'B10');
insert into ͪߩѦ듾 values('ēǻ͓Γד', 'Z01');
vacuum ͪߩѦ듾;
select * from ͪߩѦ듾;
듾 | “׾ړ | 1a󓱸
--------------------------+--------------+----------------
ēǻ͓𓽺Ó | ѦA01߾ |
ēǻ͓דȓ | B10 |
ēǻ͓Γד | Z01 |
(3 rows)
select * from ͪߩѦ듾 where “׾ړ = 'Z01';
듾 | “׾ړ | 1a󓱸
--------------------------+--------------+----------------
ēǻ͓Γד | Z01 |
(1 row)
select * from ͪߩѦ듾 where “׾ړ ~* 'z01';
듾 | “׾ړ | 1a󓱸
--------------------------+--------------+----------------
ēǻ͓Γד | Z01 |
(1 row)
select * from ͪߩѦ듾 where “׾ړ like '_Z01_';
듾 | “׾ړ | 1a󓱸
--------------------------+--------------+----------------
ēǻ͓Γד | Z01 |
(1 row)
select * from ͪߩѦ듾 where “׾ړ like '_Z%';
듾 | “׾ړ | 1a󓱸
--------------------------+--------------+----------------
ēǻ͓Γד | Z01 |
(1 row)
select * from ͪߩѦ듾 where 듾 ~ 'ēǻ[]';
듾 | “׾ړ | 1a󓱸
--------------------------+--------------+----------------
ēǻ͓𓽺Ó | ѦA01߾ |
ēǻ͓דȓ | B10 |
(2 rows)
select * from ͪߩѦ듾 where 듾 ~* 'ēǻ[]';
듾 | “׾ړ | 1a󓱸
--------------------------+--------------+----------------
ēǻ͓𓽺Ó | ѦA01߾ |
ēǻ͓דȓ | B10 |
(2 rows)
select *,character_length(듾) from ͪߩѦ듾;
듾 | “׾ړ | 1a󓱸 | char_length
--------------------------+--------------+----------------+-------------
ēǻ͓𓽺Ó | ѦA01߾ | | 8
ēǻ͓דȓ | B10 | | 7
ēǻ͓Γד | Z01 | | 8
(3 rows)
select *,octet_length(듾) from ͪߩѦ듾;
듾 | “׾ړ | 1a󓱸 | octet_length
--------------------------+--------------+----------------+--------------
ēǻ͓𓽺Ó | ѦA01߾ | | 24
ēǻ͓דȓ | B10 | | 21
ēǻ͓Γד | Z01 | | 24
(3 rows)
select *,position('' in 듾) from ͪߩѦ듾;
듾 | “׾ړ | 1a󓱸 | strpos
--------------------------+--------------+----------------+--------
ēǻ͓𓽺Ó | ѦA01߾ | | 4
ēǻ͓דȓ | B10 | | 0
ēǻ͓Γד | Z01 | | 0
(3 rows)
select *,substring(듾 from 3 for 4) from ͪߩѦ듾;
듾 | “׾ړ | 1a󓱸 | substr
--------------------------+--------------+----------------+--------------
ēǻ͓𓽺Ó | ѦA01߾ | | ͓𓽺
ēǻ͓דȓ | B10 | | ͓ד
ēǻ͓Γד | Z01 | | ͓Γ
(3 rows)
drop table test;
ERROR: Relation 'test' does not exist
create table test (t text);
insert into test values('ENGLISH');
insert into test values('FRANAIS');
insert into test values('ESPAOL');
insert into test values('SLENSKA');
insert into test values('ENGLISH FRANAIS ESPAOL SLENSKA');
vacuum test;
select * from test;
t
--------------------------------------
ENGLISH
FRANAIS
ESPAOL
SLENSKA
ENGLISH FRANAIS ESPAOL SLENSKA
(5 rows)
select * from test where t = 'ESPAOL';
t
----------
ESPAOL
(1 row)
select * from test where t ~* 'espaol';
t
--------------------------------------
ESPAOL
ENGLISH FRANAIS ESPAOL SLENSKA
(2 rows)
select *,character_length(t) from test;
t | char_length
--------------------------------------+-------------
ENGLISH | 7
FRANAIS | 8
ESPAOL | 7
SLENSKA | 8
ENGLISH FRANAIS ESPAOL SLENSKA | 33
(5 rows)
select *,octet_length(t) from test;
t | octet_length
--------------------------------------+--------------
ENGLISH | 7
FRANAIS | 9
ESPAOL | 8
SLENSKA | 9
ENGLISH FRANAIS ESPAOL SLENSKA | 36
(5 rows)
select *,position('L' in t) from test;
t | strpos
--------------------------------------+--------
ENGLISH | 4
FRANAIS | 0
ESPAOL | 7
SLENSKA | 3
ENGLISH FRANAIS ESPAOL SLENSKA | 4
(5 rows)
select *,substring(t from 3 for 4) from test;
t | substr
--------------------------------------+--------
ENGLISH | GLIS
FRANAIS | ANA
ESPAOL | PAO
SLENSKA | LENS
ENGLISH FRANAIS ESPAOL SLENSKA | GLIS
(5 rows)
drop table computer_terms;
ERROR: Relation 'computer_terms' does not exist
create table computer_terms(term text, category text, comments char(16));
create index computer_terms_index1 on computer_terms using btree(term);
create index computer_terms_index2 on computer_terms using btree(category);
insert into computer_terms values('computer display', 'X-A01-Y', 'a comment 1');
insert into computer_terms values('computer graphics', 'T-B01-Y', 'a comment 2');
insert into computer_terms values('computer programmer', 'S-Z01-Y', 'a comment 3');
vacuum computer_terms;
select * from computer_terms;
term | category | comments
---------------------+----------+------------------
computer display | X-A01-Y | a comment 1
computer graphics | T-B01-Y | a comment 2
computer programmer | S-Z01-Y | a comment 3
(3 rows)
select * from computer_terms where category = 'X-A01-Y';
term | category | comments
------------------+----------+------------------
computer display | X-A01-Y | a comment 1
(1 row)
select * from computer_terms where category ~* 'x-a01-y';
term | category | comments
------------------+----------+------------------
computer display | X-A01-Y | a comment 1
(1 row)
select * from computer_terms where category like '_-A01-_';
term | category | comments
------------------+----------+------------------
computer display | X-A01-Y | a comment 1
(1 row)
select * from computer_terms where category like '_-A%';
term | category | comments
------------------+----------+------------------
computer display | X-A01-Y | a comment 1
(1 row)
select * from computer_terms where term ~ 'computer [dg]';
term | category | comments
-------------------+----------+------------------
computer display | X-A01-Y | a comment 1
computer graphics | T-B01-Y | a comment 2
(2 rows)
select * from computer_terms where term ~* 'computer [DG]';
term | category | comments
-------------------+----------+------------------
computer display | X-A01-Y | a comment 1
computer graphics | T-B01-Y | a comment 2
(2 rows)
select *,character_length(term) from computer_terms;
term | category | comments | char_length
---------------------+----------+------------------+-------------
computer display | X-A01-Y | a comment 1 | 16
computer graphics | T-B01-Y | a comment 2 | 17
computer programmer | S-Z01-Y | a comment 3 | 19
(3 rows)
select *,octet_length(term) from computer_terms;
term | category | comments | octet_length
---------------------+----------+------------------+--------------
computer display | X-A01-Y | a comment 1 | 16
computer graphics | T-B01-Y | a comment 2 | 17
computer programmer | S-Z01-Y | a comment 3 | 19
(3 rows)
select *,position('s' in term) from computer_terms;
term | category | comments | strpos
---------------------+----------+------------------+--------
computer display | X-A01-Y | a comment 1 | 12
computer graphics | T-B01-Y | a comment 2 | 17
computer programmer | S-Z01-Y | a comment 3 | 0
(3 rows)
select *,substring(term from 10 for 4) from computer_terms;
term | category | comments | substr
---------------------+----------+------------------+--------
computer display | X-A01-Y | a comment 1 | disp
computer graphics | T-B01-Y | a comment 2 | grap
computer programmer | S-Z01-Y | a comment 3 | prog
(3 rows)
--
-- drop.source
--
--
-- this will fail if the user is not the postgres superuser.
-- if it does, don't worry about it (you can turn usersuper
-- back on as "postgres"). too many people don't follow
-- directions and run this as "postgres", though...
--
UPDATE pg_user
SET usesuper = 't'::bool
WHERE usename = 'postgres';
--
-- FUNCTION REMOVAL
--
DROP FUNCTION hobbies(person);
DROP FUNCTION hobby_construct(text,text);
DROP FUNCTION equipment(hobbies_r);
DROP FUNCTION user_relns();
DROP FUNCTION widget_in(cstring);
DROP FUNCTION widget_out(widget);
DROP FUNCTION pt_in_widget(point,widget);
DROP FUNCTION overpaid(emp);
DROP FUNCTION boxarea(box);
DROP FUNCTION interpt_pp(path,path);
DROP FUNCTION reverse_name(name);
DROP FUNCTION oldstyle_length(int4, text);
--
-- OPERATOR REMOVAL
--
DROP OPERATOR ## (path, path);
DROP OPERATOR <% (point, widget);
-- left unary
DROP OPERATOR @#@ (none, int4);
-- right unary
DROP OPERATOR #@# (int4, none);
-- right unary
DROP OPERATOR #%# (int4, none);
--
-- ABSTRACT DATA TYPE REMOVAL
--
DROP TYPE city_budget;
DROP TYPE widget;
--
-- RULE REMOVAL
-- (is also tested in queries.source)
--
--
-- AGGREGATE REMOVAL
--
DROP AGGREGATE newavg (int4);
DROP AGGREGATE newsum (int4);
DROP AGGREGATE newcnt (int4);
--
-- CLASS REMOVAL
-- (inheritance hierarchies are deleted in reverse order)
--
--
-- DROP ancillary data structures (i.e. indices)
--
DROP INDEX onek_unique1;
DROP INDEX onek_unique2;
DROP INDEX onek_hundred;
DROP INDEX onek_stringu1;
DROP INDEX tenk1_unique1;
DROP INDEX tenk1_unique2;
DROP INDEX tenk1_hundred;
DROP INDEX tenk2_unique1;
DROP INDEX tenk2_unique2;
DROP INDEX tenk2_hundred;
-- DROP INDEX onek2_u1_prtl;
-- DROP INDEX onek2_u2_prtl;
-- DROP INDEX onek2_stu1_prtl;
DROP INDEX rect2ind;
DROP INDEX rix;
DROP INDEX iix;
DROP INDEX six;
DROP INDEX hash_i4_index;
DROP INDEX hash_name_index;
DROP INDEX hash_txt_index;
DROP INDEX hash_f8_index;
-- DROP INDEX hash_ovfl_index;
DROP INDEX bt_i4_index;
DROP INDEX bt_name_index;
DROP INDEX bt_txt_index;
DROP INDEX bt_f8_index;
DROP TABLE onek;
DROP TABLE onek2;
DROP TABLE tenk1;
DROP TABLE tenk2;
DROP TABLE Bprime;
DROP TABLE hobbies_r;
DROP TABLE equipment_r;
DROP TABLE aggtest;
DROP TABLE xacttest;
DROP TABLE arrtest;
DROP TABLE iportaltest;
DROP TABLE f_star;
DROP TABLE e_star;
DROP TABLE d_star;
DROP TABLE c_star;
DROP TABLE b_star;
DROP TABLE a_star;
--
-- must be in reverse inheritance order
--
DROP TABLE stud_emp;
DROP TABLE student;
DROP TABLE slow_emp4000;
DROP TABLE fast_emp4000;
DROP TABLE emp;
DROP TABLE person;
DROP TABLE ramp;
DROP TABLE real_city;
DROP TABLE dept;
DROP TABLE ihighway;
DROP TABLE shighway;
DROP TABLE road;
DROP TABLE city;
DROP TABLE hash_i4_heap;
DROP TABLE hash_name_heap;
DROP TABLE hash_txt_heap;
DROP TABLE hash_f8_heap;
-- DROP TABLE hash_ovfl_heap;
DROP TABLE bt_i4_heap;
DROP TABLE bt_name_heap;
DROP TABLE bt_txt_heap;
DROP TABLE bt_f8_heap;
DROP TABLE ABSTIME_TBL;
DROP TABLE RELTIME_TBL;
DROP TABLE TINTERVAL_TBL;
--
-- VIRTUAL CLASS REMOVAL
-- (also tests removal of rewrite rules)
--
DROP VIEW street;
DROP VIEW iexit;
DROP VIEW toyemp;
drop table 计算机术语;
create table 计算机术语(术语 text, 分类号 varchar, 备注1A char(16));
create index 计算机术语index1 on 计算机术语 using btree(术语);
create index 计算机术语index2 on 计算机术语 using btree(分类号);
insert into 计算机术语 values('电脑显示屏','机A01上');
insert into 计算机术语 values('电脑图形','分B01中');
insert into 计算机术语 values('电脑程序员','人Z01下');
vacuum 计算机术语;
select * from 计算机术语;
select * from 计算机术语 where 分类号 = '人Z01下';
select * from 计算机术语 where 分类号 ~* '人z01下';
select * from 计算机术语 where 分类号 like '_Z01_';
select * from 计算机术语 where 分类号 like '_Z%';
select * from 计算机术语 where 术语 ~ '电脑[显图]';
select * from 计算机术语 where 术语 ~* '电脑[显图]';
select *,character_length(术语) from 计算机术语;
select *,octet_length(术语) from 计算机术语;
select *,position('显' in 术语) from 计算机术语;
select *,substring(术语 from 3 for 4) from 计算机术语;
drop table 計算機用語;
create table 計算機用語 (用語 text, 分類コード varchar, 備考1Aだよ char(16));
create index 計算機用語index1 on 計算機用語 using btree (用語);
create index 計算機用語index2 on 計算機用語 using hash (分類コード);
insert into 計算機用語 values('コンピュータディスプレイ','機A01上');
insert into 計算機用語 values('コンピュータグラフィックス','分B10中');
insert into 計算機用語 values('コンピュータプログラマー','人Z01下');
vacuum 計算機用語;
select * from 計算機用語;
select * from 計算機用語 where 分類コード = '人Z01下';
select * from 計算機用語 where 分類コード ~* '人z01下';
select * from 計算機用語 where 分類コード like '_Z01_';
select * from 計算機用語 where 分類コード like '_Z%';
select * from 計算機用語 where 用語 ~ 'コンピュータ[デグ]';
select * from 計算機用語 where 用語 ~* 'コンピュータ[デグ]';
select *,character_length(用語) from 計算機用語;
select *,octet_length(用語) from 計算機用語;
select *,position('デ' in 用語) from 計算機用語;
select *,substring(用語 from 10 for 4) from 計算機用語;
drop table 計算機용어;
create table 計算機용어 (용어 text, 分類코드 varchar, 비고1A라구 char(16));
create index 計算機용어index1 on 計算機용어 using btree (용어);
create index 計算機용어index2 on 計算機용어 using hash (分類코드);
insert into 計算機용어 values('컴퓨터디스플레이', '機A01上');
insert into 計算機용어 values('컴퓨터그래픽스', '分B10中');
insert into 計算機용어 values('컴퓨터프로그래머', '人Z01下');
vacuum 計算機용어;
select * from 計算機용어;
select * from 計算機용어 where 分類코드 = '人Z01下';
select * from 計算機용어 where 分類코드 ~* '人z01下';
select * from 計算機용어 where 分類코드 like '_Z01_';
select * from 計算機용어 where 分類코드 like '_Z%';
select * from 計算機용어 where 용어 ~ '컴퓨터[디그]';
select * from 計算機용어 where 용어 ~* '컴퓨터[디그]';
select *,character_length(용어) from 計算機용어;
select *,octet_length(용어) from 計算機용어;
select *,position('디' in 용어) from 計算機용어;
select *,substring(용어 from 3 for 4) from 計算機용어;
drop table ٸ;
create table ٸ (ɱ text, Ƴ varchar, varchar(16));
create index ٸindex1 on ٸ using btree (ɱ);
create index ٸindex2 on ٸ using hash (Ƴ);
insert into ٸ values ('', '', 'ơA01');
insert into ٸ values ('', 'ȴƳ', 'B10');
insert into ٸ values ('', 'ӡϴǹȴƳ', 'Z01Ħ');
vacuum ٸ;
select * from ٸ;
select * from ٸ where = 'Z01Ħ';
select * from ٸ where ~* 'z01Ħ';
select * from ٸ where like '_Z01_';
select * from ٸ where like '_Z%';
select * from ٸ where Ƴ ~ '[ش]';
select * from ٸ where Ƴ ~* '[ش]';
select *, character_length(ɱ) from ٸ;
select *, octet_length(ɱ) from ٸ;
select *, position('ȴ' in Ƴ) from ٸ;
select *, substring(Ƴ from 3 for 6 ) from ٸ;
drop table גђ;
create table גђ (ђ text, ʬ varchar, 1A char(16));
create index גђindex1 on גђ using btree (ђ);
create index גђindex2 on גђ using hash (ʬ);
insert into גђ values('Ԓ咡ǒג쒥','A01');
insert into גђ values('Ԓ咡钥ՒÒ','ʬB10');
insert into גђ values('Ԓ咡ג풥钥ޒ','Z01');
vacuum גђ;
select * from גђ;
select * from גђ where ʬ = 'Z01';
select * from גђ where ʬ ~* 'z01';
select * from גђ where ʬ like '_Z01_';
select * from גђ where ʬ like '_Z%';
select * from גђ where ђ ~ 'Ԓ咡[ǒ]';
select * from גђ where ђ ~* 'Ԓ咡[ǒ]';
select *,character_length(ђ) from גђ;
select *,octet_length(ђ) from גђ;
select *,position('' in ђ) from גђ;
select *,substring(ђ from 10 for 4) from גђ;
drop table Ƒ㑻;
create table Ƒ㑻( text, ֑ varchar, ע1A char(16));
create index Ƒ㑻index1 on Ƒ㑻 using btree();
create index Ƒ㑻index2 on Ƒ㑻 using btree(֑);
insert into Ƒ㑻 values('ԑԑʾ','A01');
insert into Ƒ㑻 values('ԑͼ','B01');
insert into Ƒ㑻 values('ԑ̑Ա','Z01');
vacuum Ƒ㑻;
select * from Ƒ㑻;
select * from Ƒ㑻 where ֑ = 'Z01';
select * from Ƒ㑻 where ֑ ~* 'z01';
select * from Ƒ㑻 where ֑ like '_Z01_';
select * from Ƒ㑻 where ֑ like '_Z%';
select * from Ƒ㑻 where ~ '[ԑͼ]';
select * from Ƒ㑻 where ~* '[ԑͼ]';
select *,character_length() from Ƒ㑻;
select *,octet_length() from Ƒ㑻;
select *,position('' in ) from Ƒ㑻;
select *,substring( from 3 for 4) from Ƒ㑻;
drop table ͪߩѦ듾;
create table ͪߩѦ듾 ( text, “׾ړ varchar, 1A󓱸 char(16));
create index ͪߩѦ듾index1 on ͪߩѦ듾 using btree ();
create index ͪߩѦ듾index2 on ͪߩѦ듾 using hash (“׾ړ);
insert into ͪߩѦ듾 values('ēǻ͓𓽺Ó', 'ѦA01߾');
insert into ͪߩѦ듾 values('ēǻ͓דȓ', 'B10');
insert into ͪߩѦ듾 values('ēǻ͓Γד', 'Z01');
vacuum ͪߩѦ듾;
select * from ͪߩѦ듾;
select * from ͪߩѦ듾 where “׾ړ = 'Z01';
select * from ͪߩѦ듾 where “׾ړ ~* 'z01';
select * from ͪߩѦ듾 where “׾ړ like '_Z01_';
select * from ͪߩѦ듾 where “׾ړ like '_Z%';
select * from ͪߩѦ듾 where ~ 'ēǻ[]';
select * from ͪߩѦ듾 where ~* 'ēǻ[]';
select *,character_length() from ͪߩѦ듾;
select *,octet_length() from ͪߩѦ듾;
select *,position('' in ) from ͪߩѦ듾;
select *,substring( from 3 for 4) from ͪߩѦ듾;
drop table test;
create table test (t text);
insert into test values('ENGLISH');
insert into test values('FRANAIS');
insert into test values('ESPAOL');
insert into test values('SLENSKA');
insert into test values('ENGLISH FRANAIS ESPAOL SLENSKA');
vacuum test;
select * from test;
select * from test where t = 'ESPAOL';
select * from test where t ~* 'espaol';
select *,character_length(t) from test;
select *,octet_length(t) from test;
select *,position('L' in t) from test;
select *,substring(t from 3 for 4) from test;
drop table computer_terms;
create table computer_terms(term text, category text, comments char(16));
create index computer_terms_index1 on computer_terms using btree(term);
create index computer_terms_index2 on computer_terms using btree(category);
insert into computer_terms values('computer display', 'X-A01-Y', 'a comment 1');
insert into computer_terms values('computer graphics', 'T-B01-Y', 'a comment 2');
insert into computer_terms values('computer programmer', 'S-Z01-Y', 'a comment 3');
vacuum computer_terms;
select * from computer_terms;
select * from computer_terms where category = 'X-A01-Y';
select * from computer_terms where category ~* 'x-a01-y';
select * from computer_terms where category like '_-A01-_';
select * from computer_terms where category like '_-A%';
select * from computer_terms where term ~ 'computer [dg]';
select * from computer_terms where term ~* 'computer [DG]';
select *,character_length(term) from computer_terms;
select *,octet_length(term) from computer_terms;
select *,position('s' in term) from computer_terms;
select *,substring(term from 10 for 4) from computer_terms;
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册