RE: [HACKERS] BUG found in unique index!

From: "Hiroshi Inoue" <Inoue(at)tpf(dot)co(dot)jp>
To: "Constantin Teodorescu" <teo(at)flex(dot)ro>, <pgsql-hackers(at)postgreSQL(dot)org>
Subject: RE: [HACKERS] BUG found in unique index!
Date: 1999-07-20 23:49:31
Message-ID: 000101bed30a$82d9d440$2801007e@cadzone.tpf.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> -----Original Message-----
> From: owner-pgsql-hackers(at)postgreSQL(dot)org
> [mailto:owner-pgsql-hackers(at)postgreSQL(dot)org]On Behalf Of Constantin
> Teodorescu
> Sent: Wednesday, July 21, 1999 1:53 AM
> To: pgsql-hackers(at)postgreSQL(dot)org
> Subject: [HACKERS] BUG found in unique index!
>
>
> Please Cc: to teo(at)flex(dot)ro
>
> Hello all,
>
> I think I have found a bug in unique index.
> The bug has been tested with:
> -PostgreSQL 6.5 final version running on a RedHat 5.2 i386
> -PostgreSQL 6.5 final version running on a RedHat 6.0 i386
> -PostgreSQL 6.4.2 running on a RedHat 5.2 i386
> and the results are the same.
>
> Create a test database and create the following table:
> CREATE TABLE "livrari" (
> "nr_npr" int4,
> "data_npr" date,
> "nr_ordin" int4,
> "sursa" character varying(32),
> "destinatie" character varying(32),
> "produs" character varying(8),
> "spatii_sursa" text,
> "caracteristici" text,
> "calitate" character varying(16),
> "nr_transport" character varying(16),
> "delegat" character varying(32),
> "brut" float8,
> "tara" float8,
> "net" float8,
> "cod_operatiune" int4,
> "pret" float8,
> "tva" float8,
> "qwerty12345ytrewq54321" int4);
>
> Then try creating the following unique index :
>
> test=> create unique index livrari_unic on livrari (nr_npr, data_npr,
> nr_ordin, sursa, destinatie, produs, spatii_sursa, caracteristici,
> calitate, nr_transport, delegat);
> CREATE
>

Your index has 11 columns.
Currently indices could have <= 8(7 ?) columns.
It seems create index should cause an error in this case.

Regards.

Hiroshi Inoue
Inoue(at)tpf(dot)co(dot)jp

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 1999-07-21 00:37:36 cache fixes
Previous Message Bruce Momjian 1999-07-20 23:05:12 Re: [HACKERS] Another reason to redesign querytree representation