Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1Wi4wl-0000kF-Nu for pgsql-bugs@arkaria.postgresql.org; Wed, 07 May 2014 16:43:55 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1Wi4wl-0002Aw-4T for pgsql-bugs@arkaria.postgresql.org; Wed, 07 May 2014 16:43:55 +0000 Received: from makus.postgresql.org ([2001:4800:7903:4::125]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1Wi4wi-00027Q-IR for pgsql-bugs@postgresql.org; Wed, 07 May 2014 16:43:52 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1Wi4wf-0004iW-PB for pgsql-bugs@postgresql.org; Wed, 07 May 2014 16:43:51 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id s47GhkIg030277; Wed, 7 May 2014 12:43:46 -0400 From: Tom Lane To: emanuel.calvo@2ndquadrant.com cc: pgsql-bugs@postgresql.org Subject: Re: BUG #10255: CREATE COLLATION bug on 9.4 In-reply-to: <20140507155918.1397.98656@wrigleys.postgresql.org> References: <20140507155918.1397.98656@wrigleys.postgresql.org> Comments: In-reply-to emanuel.calvo@2ndquadrant.com message dated "Wed, 07 May 2014 15:59:18 -0000" Date: Wed, 07 May 2014 12:43:46 -0400 Message-ID: <30276.1399481026@sss.pgh.pa.us> X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org emanuel.calvo@2ndquadrant.com writes: > When trying to create COLLATIONS, I'm facing some issues: I see no bugs here, just misunderstanding of the commands. > postgres=# CREATE COLLATION le_english (LOCALE = "en_US.utf8"); > ERROR: encoding "LATIN1" does not match locale "en_US.utf8" > DETAIL: The chosen LC_CTYPE setting requires encoding "UTF8". Your current database is using encoding LATIN1, so you need to reference a locale that matches that, perhaps "en_US.iso88591". (Hard to be sure about the exact spelling, since you didn't provide your platform.) > postgres=# CREATE COLLATION le_english (LOCALE = "en_US.utf8", LC_CTYPE = > "UTF8"); > ERROR: conflicting or redundant options You specify either locale or lc_ctype+lc_collate, not both. > postgres=# CREATE COLLATION le_english (LC_COLLATE = "UTF8", LC_CTYPE = > "UTF8"); > ERROR: could not create locale "UTF8": Success I get this (on RHEL6): l1=# CREATE COLLATION le_english (LC_COLLATE = "UTF8", LC_CTYPE = "UTF8"); ERROR: could not create locale "UTF8": No such file or directory DETAIL: The operating system could not find any locale data for the locale name "UTF8". which is what I'd expect, since it seems unlikely that any platform would name a locale setting just "UTF8". What seems likely is that there's something bogus about the locale data on your machine. Or maybe there's a platform-specific issue in how PG is interrogating that data ... but since you did not provide your platform information, we have no way to investigate that. regards, tom lane -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs