From: | "Hiroshi Inoue" <Inoue(at)tpf(dot)co(dot)jp> |
---|---|
To: | "John Brothers" <johnbr(at)mindspring(dot)com> |
Cc: | <pgsql-general(at)postgreSQL(dot)org>, <thoth(at)incanta(dot)net> |
Subject: | RE: [GENERAL] Primary Key Indexing problem |
Date: | 2000-01-19 05:51:46 |
Message-ID: | 001001bf6241$45359900$2801007e@tpf.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
> -----Original Message-----
> From: owner-pgsql-general(at)postgreSQL(dot)org
> [mailto:owner-pgsql-general(at)postgreSQL(dot)org]On Behalf Of John Brothers
>
> HI all,
>
> I have a script which generates a simple table, fills it with
> about 11000 unique numbers, in the primary key field,
> and then at the end, shows that the index has been
> lost for at least one of the values, allowing another
> entry to be made that duplicates the index. This is an
> abstract simplification of a problem we are experiencing in
> our field database.
>
> The compressed "script" is 64k - I didn't want to attach it to this
> message, but I would be happy to send it to anyone who might
> be able to use it to track down whatever bug(s) might be causing
> it. (I am assuming that this is a bug. If not, please accept my
> apologies).
>
> [PostgreSQL 6.5.1 on i686-pc-linux-gnu, compiled by gcc 2.7.2.3]
>
The following patch seems to fix your problem.
Regards.
Hiroshi Inoue
Inoue(at)tpf(dot)co(dot)jp
*** nbtcompare.c 2000/01/11 03:33:34 1.3
--- nbtcompare.c 2000/01/19 05:42:06
***************
*** 34,40 ****
int32
btint4cmp(int32 a, int32 b)
{
! return a - b;
}
int32
--- 34,45 ----
int32
btint4cmp(int32 a, int32 b)
{
! if (a > b)
! return 1;
! else if (a == b)
! return 0;
! else
! return -1;
}
int32
From | Date | Subject | |
---|---|---|---|
Next Message | Micheal H. | 2000-01-19 06:54:29 | examples not included |
Previous Message | yura | 2000-01-19 05:22:18 | Re: [GENERAL] launguage... |