Skip site navigation (1) Skip section navigation (2)

Re: BUG #6259: Collation Error with Citext fields

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Stan S" <ssantiago(at)adinfocenter(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #6259: Collation Error with Citext fields
Date: 2011-10-17 23:26:19
Message-ID: 21435.1318893979@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-bugs
"Stan S" <ssantiago(at)adinfocenter(dot)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

In response to

pgsql-bugs by date

Next:From: Craig RingerDate: 2011-10-18 00:48:36
Subject: Re: BUG #6255: Unable to Install (Binary, One Click Installer
Previous:From: Ric EittreimDate: 2011-10-17 22:19:22
Subject: BUG #6260: not accept password

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group