Re: Duplicate values found when reindexing unique index - Mailing list pgsql-bugs

From Tom Lane
Subject Re: Duplicate values found when reindexing unique index
Date
Msg-id 13941.1199038148@sss.pgh.pa.us
Whole thread Raw
In response to Duplicate values found when reindexing unique index  ("Mason Hale" <masonhale@gmail.com>)
Responses Re: Duplicate values found when reindexing unique index  ("Mason Hale" <masonhale@gmail.com>)
List pgsql-bugs
"Mason Hale" <masonhale@gmail.com> writes:
> Given my experience, the reliability of unique indexes is becoming somewhat
> suspect. Please help. ;-)

Well, as in the previous report, there is not enough information here to
offer much chance of understanding what's going wrong.

Have you tried reindexing that other index with the same columns in the
other order?  My guess is that there really are duplicate entries in the
table; if so the other one should fail too.  If so, please try to
identify the duplicated values, along the lines of

    select guid, feed_id from entry group by 1,2 having count(*) > 1

and show us the system columns (ctid,xmin,xmax,cmin,cmax) from the
tuples having duplicate value(s).  Note that you should probably disable
indexscan and bitmapscan while doing this probing, so as not to have the
queries use the suspect indexes.

This is 8.2.5 right?  Was the DB loaded fresh into 8.2.5, or was it
inherited from previous 8.2.x release(s)?

BTW, what are the datatypes of the index columns?

            regards, tom lane

pgsql-bugs by date:

Previous
From: Bill Moran
Date:
Subject: Re: BUG #3845: tray icon that service is running
Next
From: Tom Lane
Date:
Subject: Re: Duplicate values found when reindexing unique index