Re: Bad records in table

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Bad records in table
Дата
Msg-id 18430.1025636407@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Bad records in table  ("Peter Darley" <pdarley@kinesis-cem.com>)
Ответы Re: Bad records in table  ("Peter Darley" <pdarley@kinesis-cem.com>)
Список pgsql-general
"Peter Darley" <pdarley@kinesis-cem.com> writes:
> I can identify the bad records with a simple perl script that reads all the
> records sequentially and lets me know which ones crash the back end.  Now
> that I know which ones they are, how can I get rid of them?

DELETE?

That might not work very well if the corruption is in toasted fields,
but you haven't given any details that would let us know (not even such
basic info as your PG version).

But before doing that I'd suggest eyeballing the bad data using a tool
such as pg_filedump (see http://sources.redhat.com/rhdb/tools.html).
Look at the "ctid" column of the bad tuples to see what part of the
file you need to dump (ctid is block number and item number).  The
pattern of the corruption might give some clue what happened.

            regards, tom lane



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

Предыдущее
От: hyldgaard@hotmail.com (Thomas Hyldgaard)
Дата:
Сообщение: Comparing PostgreSQL and Oracle stability
Следующее
От: grant
Дата:
Сообщение: Re: namespaces and schemas