Re: BUG #3965: UNIQUE constraint fails on long column values - Mailing list pgsql-bugs

From Kris Jurka
Subject Re: BUG #3965: UNIQUE constraint fails on long column values
Date
Msg-id Pine.BSO.4.64.0802181914100.11576@leary.csoft.net
Whole thread Raw
In response to Re: BUG #3965: UNIQUE constraint fails on long column values  (Bruce Momjian <bruce@momjian.us>)
List pgsql-bugs
On Mon, 18 Feb 2008, Bruce Momjian wrote:

> Juho Saarikko wrote:
>> While I didn't test, I'd imagine that this would also mean that any attempt
>> to insert such values to an already unique column would fail.
>
> Works here in 8.3:
>
>     test=> insert into test values (repeat('a', 50000) || 'b');
>

This only works because it gets toasted before being put in the index.
Since you've selected something real compressible, you can fit 50k chars
into it.

Kris Jurka

pgsql-bugs by date:

Previous
From: "Faheem Mitha"
Date:
Subject: BUG #3968: ssh tunnel instructions could use improvement
Next
From: Juho Saarikko
Date:
Subject: Re: BUG #3965: UNIQUE constraint fails on long column values