Re: simple_heap_update: tuple concurrently updated -- during INSERT - Mailing list pgsql-hackers

From SZŰCS Gábor
Subject Re: simple_heap_update: tuple concurrently updated -- during INSERT
Date
Msg-id 025a01c44e3c$81fcf720$0403a8c0@fejleszt4
Whole thread Raw
In response to simple_heap_update: tuple concurrently updated -- during INSERT  ("SZŰCS Gábor" <surrano@mailbox.hu>)
List pgsql-hackers
Dear Tom,

Thanks for your reply.
Thinking about it, yes; there are triggers that (may) do updates on this
table, and there is a master table "pakolas" ("pakolas_cikktetel" is a
detail of it) that I touch, and yes, it has a NOTIFY in AFTER trigger. (that
is one of the causes I touch that table ;) )

Q1. So is this everything that can be said -- NOTIFY calls
simple_heap_update that is concurrently updated by a different transaction?

Q2. I'm not sure if it's a good idea, but if the transaction simply fails
due to a NOTIFY, can I hack around it so that it won't ruin the entire
transaction, only NOTIFY?

Q3. Is there a way to degrade this error to warning or maybe notice (without
recompiling the server source ;) )?

Thanks again,
G.
%----------------------- cut here -----------------------%
\end

----- Original Message -----
From: "Tom Lane" <tgl@sss.pgh.pa.us>
To: "SZŰCS Gábor" <surrano@mailbox.hu>
Cc: "PGH" <pgsql-hackers@postgresql.org>
Sent: Wednesday, June 09, 2004 5:23 PM
Subject: Re: [HACKERS] simple_heap_update: tuple concurrently updated --
during INSERT


> "SZŰCS Gábor" <surrano@mailbox.hu> writes:
> >   ERROR:  simple_heap_update: tuple concurrently updated.
> >   LOG:  statement: INSERT INTO pakolas_cikktetel
> >     (cikk, minoseg, helyrol, mennyi, pakolas, sorszam, helyre) VALUES
> >     (102165, 1, 1488, '25', 68615, 1, 1338)
>
> Hmm.  AFAIK, an INSERT statement per se will never call
> simple_heap_update at all --- that routine is only used for system
> catalog updates.  I'm wondering what is going on behind the scenes
> here.  Have you got any triggers or rules that this INSERT would
> fire, and if so what do they do?  Maybe you are using NOTIFY?
>
> regards, tom lane
>



pgsql-hackers by date:

Previous
From: "Jim C. Nasby"
Date:
Subject: Re: Frequently updated tables
Next
From: pgsql@mohawksoft.com
Date:
Subject: Re: Frequently updated tables