Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id A7DD9476075 for ; Mon, 20 Jan 2003 10:18:07 -0500 (EST) Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by postgresql.org (Postfix) with ESMTP id DC29E476021 for ; Mon, 20 Jan 2003 10:18:06 -0500 (EST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.6/8.12.6) with ESMTP id h0KFIA5u003022; Mon, 20 Jan 2003 10:18:10 -0500 (EST) To: Bhuvan A Cc: pgsql-admin@postgresql.org Subject: Re: deadlock problem in Ad serving.. In-reply-to: References: Comments: In-reply-to Bhuvan A message dated "Mon, 20 Jan 2003 15:32:33 +0530" Date: Mon, 20 Jan 2003 10:18:10 -0500 Message-ID: <3021.1043075890@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200301/206 X-Sequence-Number: 7048 Bhuvan A writes: >> ~~~~~~~~~~~~~~~~~~~~~~ >> Error: DBD::Pg::st execute failed: ERROR: deadlock detected at >> /usr/local/perlapache/lib/perl/Banner.pm line 71, line 7. >> ~~~~~~~~~~~~~~~~~~~~~~ > It is a genuine error, occurs while two or more transaction process tries > to update/delete a same record simultaneously. You can overcome this by > locking the table in share row exclusive mode also. That will just move his problem somewhere else. I think the only real answer is to use shorter transactions (one per page, not one per several pages). regards, tom lane