Re: UTF-8 encoding failure

From: "Hiroshi Saito" <z-saito(at)guitar(dot)ocn(dot)ne(dot)jp>
To: Martin Schäfer <Martin(dot)Schaefer(at)cadcorp(dot)com>, "'Takahiro Itagaki'" <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp>
Cc: <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: UTF-8 encoding failure
Date: 2010-03-26 14:35:30
Message-ID: ECCCA4487C8542618EAB90A5783236DC@acer08f817a9b5
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hi.

Ahh ok, Would you try this.

C:\home\HIROSHI>"C:\Program Files\PostgreSQL\8.4\bin\psql.exe" -f SJIS_TEST.SQL
-p5433 postgres postgres
データベ
ース一覧
\x96\xBC\x91O | \x8F\x8A\x97L\x8E | \x83G\x83\x93\x83R\x81[\x83f\x83B\x83\x93\x
83O | \x8Fニ構x87\x8F\x87\x8F\x98 | Ctype(\x95マ浬xB7\x89\x89\x8EZ\x8Eq) | \x83A\x
83N\x83Z\x83X\x8C\xA0
---------------+-------------------+--------------------------------------------
----+---------------------------+------------------------------------+----------
--------------------
postgres | postgres | UTF8
| C | C |
template0 | postgres | UTF8
| C | C | =c/postgr
es

: postgres=
CTc/postgres
template1 | postgres | UTF8
| C | C | =c/postgr
es

: postgres=
CTc/postgres
(3 行)

UTF8
SJIS
psql:SJIS_TEST.SQL:5: NOTICE: CREATE TABLE / PRIMARY KEY will create implicit i
ndex "漢字テーブル_pkey" for table "漢字テーブル"
CREATE TABLE
INSERT 0 1
INSERT 0 1
へんかん | どうですか
------------+------------
さいとう | ひろし
こんにちは | ひろしです
(2 行)

DROP TABLE

----- Original Message -----
From: "Martin Schäfer" <Martin(dot)Schaefer(at)cadcorp(dot)com>

> Hello Hiroshi-san,
>
> The only differences I found between my source file and yours are the file encoding
> (Unicode/SJIS), different #include-s and different parameters to PQsetdblogin. I had to
> undo the last two changes to compile and run on my machine. And the changed file encoding
> made no difference. It still fails on my machine.
>
> Regards,
>
> Martin

Attachment Content-Type Size
SJIS_TEST.SQL application/octet-stream 313 bytes

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Martin Schäfer 2010-03-26 14:49:15 Re: UTF-8 encoding failure
Previous Message Alan McKay 2010-03-26 14:32:53 Solid State Drives with PG (was: in RAM DB)