Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit199f597

Browse files
committed
Improve test for CONVERT() with GB18030 <-> UTF8.
Add a bit of coverage of high code points.Arjen Nienhuis
1 parent26df706 commit199f597

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

‎src/test/regress/expected/conversion.out

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -523,17 +523,17 @@ SELECT CONVERT('foo', 'UTF8', 'EUC_TW');
523523
(1 row)
524524

525525
-- GB18030 --> UTF8
526-
SELECT CONVERT('foo', 'GB18030', 'UTF8');
527-
convert
528-
---------
529-
foo
526+
SELECT CONVERT('Postgres \247\343\247\335\247\340\247\337 \2249\3138 \317\363 \250\246le\2010\2747phant', 'GB18030', 'UTF8');
527+
convert
528+
-------------------------------------------------------------------------------------------------
529+
Postgres \321\201\320\273\320\276\320\275 \360\237\220\230 \350\261\241 \303\251le\314\201phant
530530
(1 row)
531531

532532
-- UTF8 --> GB18030
533-
SELECT CONVERT('foo', 'UTF8', 'GB18030');
534-
convert
535-
---------
536-
foo
533+
SELECT CONVERT('Postgres \321\201\320\273\320\276\320\275 \360\237\220\230 \350\261\241 \303\251le\314\201phant', 'UTF-8', 'GB18030');
534+
convert
535+
-----------------------------------------------------------------------------------------
536+
Postgres \247\343\247\335\247\340\247\337 \2249\3138 \317\363 \250\246le\2010\2747phant
537537
(1 row)
538538

539539
-- GBK --> UTF8

‎src/test/regress/sql/conversion.sql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,9 +171,9 @@ SELECT CONVERT('foo', 'EUC_TW', 'UTF8');
171171
-- UTF8 --> EUC_TW
172172
SELECTCONVERT('foo','UTF8','EUC_TW');
173173
-- GB18030 --> UTF8
174-
SELECTCONVERT('foo','GB18030','UTF8');
174+
SELECTCONVERT('Postgres\247\343\247\335\247\340\247\337\2249\3138\317\363\250\246le\2010\2747phant','GB18030','UTF8');
175175
-- UTF8 --> GB18030
176-
SELECTCONVERT('foo','UTF8','GB18030');
176+
SELECTCONVERT('Postgres\321\201\320\273\320\276\320\275\360\237\220\230\350\261\241\303\251le\314\201phant','UTF-8','GB18030');
177177
-- GBK --> UTF8
178178
SELECTCONVERT('foo','GBK','UTF8');
179179
-- UTF8 --> GBK

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp