Kamil Kaczkowski <kamil(at)kamil(dot)eisp(dot)pl> writes:
>> Another possible explanation is if the UPDATE
>> command can update more than one row --- in that case different backends
>> might happen to reach the target rows in different orders.
> Yes, this UPDATE changes several rows, I didn't know this can be a
> My understanding was that row-level lock at UPDATE statement is somehow
> atomic and it locks all rows matched at once.
> But what's the solution? How can I force UPDATEs to lock rows in the same
> order? There's no ORDER BY clause for UPDATE.
Change things so you don't need to update more than one row per query,
perhaps? The lack of any primary key on that table was already pretty
disturbing from a database-theory point of view. Maybe you should
rethink the table layout.
regards, tom lane
In response to
pgsql-general by date
|Next:||From: Ennio-Sr||Date: 2004-11-27 01:36:05|
|Subject: Re: Can you help solve restore problem?|
|Previous:||From: Adrian Klaver||Date: 2004-11-27 00:59:51|
|Subject: Re: pg_dump and languages|