X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 20DBF3A4B86 for ; Sun, 14 Nov 2004 00:12:52 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 14068-04 for ; Sun, 14 Nov 2004 00:12:32 +0000 (GMT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id D0BBA3A3D6D for ; Sun, 14 Nov 2004 00:12:33 +0000 (GMT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id iAE0CT0h004027; Sat, 13 Nov 2004 19:12:31 -0500 (EST) To: Dan Libby Cc: pgsql-admin@postgresql.org Subject: Re: dump/restore results in duplicate key violation with 7.4.6. In-reply-to: <418F08C7.60305@libby.com> References: <418BD67D.1010108@osc.co.cr> <418BE4A2.1060506@libby.com> <418F08C7.60305@libby.com> Comments: In-reply-to Dan Libby message dated "Sun, 07 Nov 2004 23:48:55 -0600" Date: Sat, 13 Nov 2004 19:12:28 -0500 Message-ID: <4026.1100391148@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200411/112 X-Sequence-Number: 15496 Dan Libby writes: > 1) I don't understand why a difference in locale should cause a > duplicate key error, especially when both databases were created using > 'UNICODE' encoding. Is this valid behavior or a postgres bug? The past reports I've seen of such misbehavior appeared to result from strcoll() failing to cope well with multibyte sequences that were illegal according to the selected locale's idea of the character set in use. You can get burnt by this quite easily if you set the database encoding to something not compatible with the locale. If you didn't make that mistake, then I'd bet on Postgres having a more liberal idea of what are valid characters in the encoding than the locale definition does. Whether that is Postgres' bug or the locale definition's is impossible to say without more data. regards, tom lane