Received: from sss.pgh.pa.us ([192.204.191.242]) by postgresql.org (8.11.3/8.11.4) with ESMTP id g0BM15B49485 for ; Fri, 11 Jan 2002 17:01:05 -0500 (EST) (envelope-from tgl@sss.pgh.pa.us) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.11.4/8.11.4) with ESMTP id g0BM15g01890; Fri, 11 Jan 2002 17:01:05 -0500 (EST) To: "Mir S Islam" cc: pgsql-sql@postgresql.org Subject: Re: who has lock on table/row In-reply-to: <001301c19585$28c36e90$0100a8c0@sjc.mindspring.net> References: <001301c19585$28c36e90$0100a8c0@sjc.mindspring.net> Comments: In-reply-to "Mir S Islam" message dated "Fri, 04 Jan 2002 17:06:08 -0800" Date: Fri, 11 Jan 2002 17:01:04 -0500 Message-ID: <1887.1010786464@sss.pgh.pa.us> From: Tom Lane X-Archive-Number: 200201/137 X-Sequence-Number: 6225 "Mir S Islam" writes: > Is there a way to find out who(if any) has lock on a table ? Not at the moment. We need a utility to dump out the contents of the lock manager's data structures, but no one's got round to it. > Basically I am > trying to do an insert update transaction and it is waiting and waitin until > I hit cancel. Since the application heavily uses transactions/commits I am > assuming somewhere it is leaving something open because of which the > following queries are not updating. Try using "ps" to look for a backend that is sitting in "idle in transaction" state. regards, tom lane