Re: BUG #6259: Collation Error with Citext fields - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #6259: Collation Error with Citext fields
Date
Msg-id 21435.1318893979@sss.pgh.pa.us
Whole thread Raw
In response to BUG #6259: Collation Error with Citext fields  ("Stan S" <ssantiago@adinfocenter.com>)
List pgsql-bugs
"Stan S" <ssantiago@adinfocenter.com> writes:
> shard_1=# CREATE TABLE users (nickname CITEXT PRIMARY KEY,pass TEXT   NOT
> NULL);
> NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "users_pkey"
> for table "users"

> shard_1=# INSERT INTO users VALUES ( 'larry',  'aaa' );
> INSERT 0 1

> shard_1=# INSERT INTO users VALUES ( 'Tom',   'bbb' );
> ERROR:  could not determine which collation to use for string comparison
> HINT:  Use the COLLATE clause to set the collation explicitly.

Hmm, I can't replicate this here ...

> shard_1=# CREATE TABLE users (nickname CITEXT COLLATE "C" PRIMARY KEY,pass
TEXT   NOT NULL);
> ERROR:  collations are not supported by type citext

This suggests strongly that you're using a 9.0-or-earlier citext
installation that you've not upgraded to 9.1.  If that's the right
guess, you need to do CREATE EXTENSION citext FROM unpackaged
to fix it.

            regards, tom lane

pgsql-bugs by date:

Previous
From: "Ric Eittreim"
Date:
Subject: BUG #6260: not accept password
Next
From: Craig Ringer
Date:
Subject: Re: BUG #6255: Unable to Install (Binary, One Click Installer