X-Original-To: pgsql-admin-postgresql.org@postgresql.org Received: from localhost (wm.hub.org [200.46.204.128]) by postgresql.org (Postfix) with ESMTP id DA0B09FB415 for ; Thu, 31 Aug 2006 15:11:04 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.128]) (amavisd-new, port 10024) with ESMTP id 18311-06-4 for ; Thu, 31 Aug 2006 18:11:01 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey- Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by postgresql.org (Postfix) with ESMTP id 5F9299FB423 for ; Thu, 31 Aug 2006 15:10:47 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.6/8.13.6) with ESMTP id k7VI9rLM022112; Thu, 31 Aug 2006 14:09:54 -0400 (EDT) To: Alvaro Herrera cc: Naomi Walker , "pgsql-admin@postgresql.org" , William Bloom Subject: Re: Upgrading from 7.4 to 8.1 In-reply-to: <20060831032626.GM22618@alvh.no-ip.org> References: <44F622E0.6040009@eldocomp.com> <20060831032626.GM22618@alvh.no-ip.org> Comments: In-reply-to Alvaro Herrera message dated "Wed, 30 Aug 2006 23:26:26 -0400" Date: Thu, 31 Aug 2006 14:09:53 -0400 Message-ID: <22111.1157047793@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200608/357 X-Sequence-Number: 22900 Alvaro Herrera writes: > What are the exact options? I tried to reproduce it here, using a 8.1 > and 8.2 pg_dumpall, and a 7.4 server, and couldn't. >> CREATE ROLE ""; >> ALTER ROLE "" WITH NOSUPERUSER INHERIT NOCREATEROLE NOCREATEDB LOGIN; > This is weird anyway -- do you really have a role named "" (empty > string)? It's not "empty string", it's '\003' as shown by the failure: query was: SELECT useconfig[1] FROM pg_shadow WHERE usename = E'\003' The problem is evidently that appendStringLiteral tries to use E syntax in an inappropriate context, ie, while talking to a server that doesn't understand it. This is fixed in HEAD (by using appendStringLiteralConn) but I'm not sure if there is any very good way to fix it in the back branches. In the short term, Naomi's best workaround is surely to drop or rename that user ... it hardly seems likely that the name is anything but a typo. regards, tom lane