Re: How to delete completely duplicate rows

Поиск
Список
Период
Сортировка
От bricklen
Тема Re: How to delete completely duplicate rows
Дата
Msg-id CAGrpgQ-g9m0YTAupqe6VTjg6tb65cYHwZFrTAnpyU0FjpFnWsA@mail.gmail.com
обсуждение исходный текст
Ответ на How to delete completely duplicate rows  ("Janek Sendrowski" <janek12@web.de>)
Ответы Re: How to delete completely duplicate rows
Список pgsql-general

On Wed, Jan 1, 2014 at 4:14 AM, Janek Sendrowski <janek12@web.de> wrote:
I want to delete duplicates in my table. I've dropped the unique constraint to insert my data.
My id value is a hash calculated witch the values of the two other columns.
So I want to delete all columns, which are indentical, but keeping one.
 
DELETE FROM table t1 USING table t2 WHERE t1.id = t2.id AND t1.ctid > t2.ctid

But the oids aren't unique enough.
What else could I do?

В списке pgsql-general по дате отправления:

Предыдущее
От: Jayadevan M
Дата:
Сообщение: Re: Refresh Materialized View
Следующее
От: "Reiser, John J."
Дата:
Сообщение: duplicate OID issue when using pg_upgrade to move from 8.4 to 9.2