Re: Primary key duplicates - Mailing list pgsql-bugs

From Zeki Mokhtarzada
Subject Re: Primary key duplicates
Date
Msg-id Pine.LNX.4.44.0408132231290.17597-100000@freewebz.com
Whole thread Raw
In response to Re: Primary key duplicates  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
It appears that I can select the rows, but not delete or update them.

# select ctid from files where ctid = '(53101,30)';
    ctid
------------
 (53101,30)
(1 row)

# delete from files where ctid = '(53101,30)';
DELETE 0
# update files set fileid = 1000 where ctid = '(53101,30)';
UPDATE 0
#

-Zeki

On Fri, 13 Aug 2004, Tom Lane wrote:

> Zeki Mokhtarzada <zeki@freewebz.com> writes:
> > The system is running on a Dell PowerEdge 2650 running RedHat 8.  We had a
> > kernel halt about two weeks ago that was caused by one of our disk mirrors
> > failing.  It could be that these problems were caused at that point in
> > time and are just being noticed now.
>
> Not sure.  xmin=2 (FrozenXid) implies that those rows have been like
> that for a good long time (~ 1 billion transactions).
>
> > But you never stated how to delete the duplicate rows.  Any suggestions?
>
> You can select 'em by ctid, viz WHERE ctid = '(53101,30)'
>
>             regards, tom lane
>

pgsql-bugs by date:

Previous
From: Zeki Mokhtarzada
Date:
Subject: Re: Primary key duplicates
Next
From: "Jim J."
Date:
Subject: Configure error Beta 8.0.0