Re: Help: unfixable/undead error - missing chunk number 0 for toast value 413511 in pg_toast_25477

From: Jorge Torralba <jorge(dot)torralba(at)gmail(dot)com>
To: Maris Jansons <maris(at)lailio(dot)net>
Cc: pgsql-admin <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Help: unfixable/undead error - missing chunk number 0 for toast value 413511 in pg_toast_25477
Date: 2017-01-25 21:52:08
Message-ID: CACut7uR8ohqdDkn-343SZbBwu-stXRLeZf051dgyrQVaFidQ+g@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

I have run this with success several times. I modified it to be intuitive.
There may be a typo or two but have a look at this:

DO $f$

DECLARE

baddata TEXT;

badid INT;

BEGIN

FOR badid IN SELECT id FROM badtable LOOP

BEGIN

SELECT badcolumn

INTO columndata

FROM badtable where id = badid;

EXCEPTION

WHEN OTHERS THEN

RAISE NOTICE 'Data for ID % is corrupt', badid;

CONTINUE;

END;

END LOOP;

END;

$f$

On Wed, Jan 25, 2017 at 1:30 PM, Maris Jansons <maris(at)lailio(dot)net> wrote:

> Hello,
> > A couple things you can try.
> > 1. reindex your toast table.
> > 2. write a loop that ..
>
> I already have done both, did not help, check the original message for
> details.
>
> Best Regards,
> Maris.
>
>

--
Thanks,

Jorge Torralba
----------------------------

Note: This communication may contain privileged or other confidential
information. If you are not the intended recipient, please do not print,
copy, retransmit, disseminate or otherwise use the information. Please
indicate to the sender that you have received this email in error and
delete the copy you received. Thank You.

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Maris Jansons 2017-01-26 09:44:21 Re: Help: unfixable/undead error - missing chunk number 0 for toast value 413511 in pg_toast_25477
Previous Message Maris Jansons 2017-01-25 21:30:47 Re: Help: unfixable/undead error - missing chunk number 0 for toast value 413511 in pg_toast_25477