Re: Duplicate rows in table with unique index

From: Mark D Powell <Mark.Powell_at_eds.com>
Date: 11 Mar 2003 18:23:11 -0800
Message-ID: <2687bb95.0303111823.39f76efd_at_posting.google.com>


biagio.scognamiglio_at_convergere.com (Biagio) wrote in message news:<7762c0a8.0303110434.195a3d46_at_posting.google.com>...
> hi all,
>
> I found several duplicate rows in a table where a unique index exists
> and is valid. Could anybody suggest me how to recover the situation
> without invalidating the index and corrupting the table data?
>
> Someone could explain to me as this could happen?
>
> This happen on Oracle 8.1.7.0.0, Sun Sparc 32bit release.
>
>
> thanks,
> Biagio

Biagio, a couple of things you can check

Did you verify the index is unique via dba_indexes or did you assume the index is unique because the table has a PK?

Since version 8.0 it has been possible to support a PK using a non-unique index and constraints can be turned on without validating existing data.

Next, on the list might be selecting the duplicated key rows and using the dump function on the columns to make sure there isn't a trailing character of some type in one of the columns technically making the data unique.

Once you have checked the above I would go to metalink and try searching around to see what you can find. Then I would enter an iTAR if you have support. I seem to remember a couple of posts on this, but cannot remember the outcome.

HTH -- Mark D Powell -- Received on Wed Mar 12 2003 - 03:23:11 CET

Original text of this message