Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 556E41337B69 for ; Thu, 3 Mar 2011 12:12:23 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 58558-06 for ; Thu, 3 Mar 2011 16:12:15 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-iy0-f174.google.com (mail-iy0-f174.google.com [209.85.210.174]) by mail.postgresql.org (Postfix) with ESMTP id 0657B133655C for ; Thu, 3 Mar 2011 12:12:14 -0400 (AST) Received: by iyb26 with SMTP id 26so1053001iyb.19 for ; Thu, 03 Mar 2011 08:12:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=HpjW8gwaRov5QaIP1HaZiUc2bQOmjztFZPT4c33o2Cc=; b=P+u5ClMVaT8//uzARu+dtkYHVkGfQ/T6OvbrI8u8c40mzdACGFExBNkyuH45uabu2g q1+Y1T7JEn6TU1XsqBWIHgOdpKtQt/vjUPsA/dW51z4QeG/PckvCTZpZM+2gljRqeY+L L3aKTHNTxFzs7UlMba8v6irFx8gigth+kCuKg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=WuDN5xJ8n14tvQsUe7/R5sxR/WNUXsXskB/B/lNcNTTZDi0/p3yR88lnupUySAj25l c/l1mAqJ3F3Z94TPkCbgoHq6/3mxwCBATzSA1o/ABFJrP+XRE6oBUOxX0J8taZtTyEPK ECz+L1/MgMkM2GACUKyVo1p0QiN8w+9imrij4= MIME-Version: 1.0 Received: by 10.42.142.196 with SMTP id t4mr1785464icu.263.1299168734362; Thu, 03 Mar 2011 08:12:14 -0800 (PST) Received: by 10.43.68.208 with HTTP; Thu, 3 Mar 2011 08:12:14 -0800 (PST) In-Reply-To: <201101070642.p076ggoG059006@wwwmaster.postgresql.org> References: <201101070642.p076ggoG059006@wwwmaster.postgresql.org> Date: Thu, 3 Mar 2011 11:12:14 -0500 Message-ID: Subject: Re: BUG #5818: initdb lose the single quote of locale From: Robert Haas To: yulei Cc: pgsql-bugs@postgresql.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-0.67 tagged_above=-5 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, FREEMAIL_REPLY=1.929, RCVD_IN_DNSWL_LOW=-0.7 X-Spam-Level: X-Archive-Number: 201103/44 X-Sequence-Number: 29554 On Fri, Jan 7, 2011 at 1:42 AM, yulei wrote: > > The following bug has been logged online: > > Bug reference: =C2=A0 =C2=A0 =C2=A05818 > Logged by: =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0yulei > Email address: =C2=A0 =C2=A0 =C2=A0yu1ei@hotmail.com > PostgreSQL version: 9.0.2 > Operating system: =C2=A0 Windows XP Service Pack 3 > Description: =C2=A0 =C2=A0 =C2=A0 =C2=A0initdb lose the single quote of l= ocale > Details: > > Hi,dear developers! > I am using a chinses window xp os. > i run "initdb -E UTF-8 -D temp" in cmd,it can get the > locale:"Chinese_People's Republic of China.936"=E3=80=82 > > but when initdb =C2=A0creating template1 , it lose the single quote of lo= cale,it > use "Chinese_Peoples Republic of China.936"(notice that , it lose the ' > after "Chinese_People" ) for the "template1" record's > =E2=80=9Cdatcollate=E2=80=9D,=E2=80=9Cdatctype=E2=80=9D Column in tablepg= _database=E3=80=82 > > though "creating template1 database" is ok,but the initdb's next step > "initializing pg_authid ..." failed. > bucause the invalid locale "Chinese_People's Republic of China.936" is us= ed > to run the command "REVOKE ALL on pg_authid FROM public;"=E3=80=82 > > and the cmd resule is : > creating template1 database in temp/base/1 ... ok > initializing pg_authid ... : =C2=A0=DD=BF=CA=B9=C3=B5=D4=BB=CD=B2=CF=B5= =CD=B3=C4=B2 > =CF=B8=CF=A2: =C2=A0=DD=BF=E2=BC=AF=C8=BA LC_COLLATE "Chinese_Peoples Re > =CA=BE: =C2=A0=D2=BB=D4=BB=C2=B4=DD=BF=E2=A3=AC=DF=B0=D7=B0=CA=A7=D4=BB. > child process exited with exit code 1 > initdb: removing data directory "temp"=E3=80=82 > > to support what i say , i test like: > add " > create pg_database_test 5158 ( datname =3D name ) > open pg_database_test > insert OID =3D 1 ( "Chinese_People's Republic of China.936") > close pg_database_test > " > =C2=A0to postgreSQLHOME/share/postgres.bki > > run cmd "initdb -E UTF-8 -D temp --local=3Dchs" > > it can init successful,then i start the server,run sql: > "SELECT * from pg_database_test" ,the result show "Chinese_Peoples Republ= ic > of China.936". > yes ,the single quote of test string "Chinese_People's Republic of > China.936" lose. > > can you fix it ? I don't see any responses to this bug. Do we have a quoting problem somewh= ere? --=20 Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company