[pgsql-jp: 28778] 空文字列を含むテーブルの\copy/pg_dumpが失敗する

naoki kishida kishida @ fk.urban.ne.jp
2003年 1月 26日 (日) 16:11:26 JST


きしだです

psqlから\copyでテーブルの空の文字列(nullではなく)を含むテーブルをエクス
ポートしようとすると、以下のようなメッセージが出て失敗してしまいます。

server closed the connection unexpectedly
        This probably means the server terminated abnormally
        before or while processing the request.
The connection to the server was lost. Attempting reset: WARNING:  Message from PostgreSQL backend:
        The Postmaster has informed me that some other backend
        died abnormally and possibly corrupted shared memory.
        I have rolled back the current transaction and am
        going to terminate your database system connection and exit.
        Please reconnect to the database system and repeat your query.
Failed.
\copy: connection pointer is NULL


update table_name set field_name=null where field_name='';
などとして空文字列をnullにすれば、正常に終了します。
もちろん、その後
update table_name set field_name='' where field_name is null;
とすると以前と同様に失敗します。

\copyが失敗するため、pg_dumpも失敗します。

これはどういった現象なのでしょうか。


データベースはunicodeになってます。
PostgreSQLのバージョンは7.3です。

----
岸田 哉生(きしだ なおき)
	email:kishida @ fk.urban.ne.jp
	http://www.fk.urban.ne.jp/home/kishida/




pgsql-jp メーリングリストの案内