Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 2899E4770BD for ; Mon, 6 Jan 2003 13:42:42 -0500 (EST) Received: from megazone.bigpanda.com (megazone.bigpanda.com [63.150.15.178]) by postgresql.org (Postfix) with ESMTP id 5141F47720C for ; Mon, 6 Jan 2003 13:42:18 -0500 (EST) Received: by megazone.bigpanda.com (Postfix, from userid 1001) id 225F7D609; Mon, 6 Jan 2003 10:42:18 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by megazone.bigpanda.com (Postfix) with ESMTP id 17E3D5C04; Mon, 6 Jan 2003 10:42:18 -0800 (PST) Date: Mon, 6 Jan 2003 10:42:18 -0800 (PST) From: Stephan Szabo To: Jack Flak Cc: Subject: Re: restore/dup OIDs HELP! In-Reply-To: <3iQR9.6166$My.301037750@newssvr14.news.prodigy.com> Message-ID: <20030106103627.Q47795-100000@megazone23.bigpanda.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200301/36 X-Sequence-Number: 6878 On Sun, 5 Jan 2003, Jack Flak wrote: > Greetings Group, > > I'm running 7.1. > > Basically, my question is this: how do I delete an exact dup without > deleting the original? You can use one of the other hidden fields. ctid will be unique for the various rows, but I'm not sure of a good way to bulk delete them (tids don't seem to have comparison operators so the normal ways I can think of don't work). If all of the new rows were added by a single transaction (through copy say) you'd probably be able to delete all the rows added by that transaction using the xmin column. Find the xmin belonging to those rows and delete all the rows having that xmin.