Re: foreign key on delete cascade order? - Mailing list pgsql-general

From Tom Lane
Subject Re: foreign key on delete cascade order?
Date
Msg-id 658814.1646933907@sss.pgh.pa.us
Whole thread Raw
In response to Re: foreign key on delete cascade order?  (George Woodring <george.woodring@iglass.net>)
Responses Re: foreign key on delete cascade order?
List pgsql-general
George Woodring <george.woodring@iglass.net> writes:
> I have always thought the way to avoid deadlocks was to update rows in the
> same order by the different updaters.  Is there a better chain of thought
> for updating and deleting rows at the same time?  Do we need to put a lock
> on the table to update, then have the delete queue up waiting for the lock
> to be removed?

With the amount of detail you've provided (viz: none), it's impossible
for anyone to guess what your problem actually is, let alone speculate
on suitable solutions.

            regards, tom lane



pgsql-general by date:

Previous
From: George Woodring
Date:
Subject: Re: foreign key on delete cascade order?
Next
From: Durumdara
Date:
Subject: Am I in the same transaction block in complex PLPGSQL?