Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id 91C4164FCD8 for ; Wed, 16 Jul 2008 05:22:51 -0300 (ADT) Received: from postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 40184-06 for ; Wed, 16 Jul 2008 05:22:14 -0300 (ADT) X-Greylist: delayed 00:19:42.039082 by SQLgrey-1.7.6 Received: from mail.mnc.ch (62-2-77-205.static.cablecom.ch [62.2.77.205]) by postgresql.org (Postfix) with ESMTP id 3805D64FCDE for ; Wed, 16 Jul 2008 05:21:25 -0300 (ADT) Received: from localhost (mail2.mnc.ch [127.0.0.1]) by mail.mnc.ch (Postfix) with ESMTP id B296F23079; Wed, 16 Jul 2008 08:01:32 +0000 (GMT) X-Virus-Scanned: amavisd-new at mnc.ch Received: from mail.mnc.ch ([127.0.0.1]) by localhost (mail2.mnc.ch [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id qh7TULzhcppv; Wed, 16 Jul 2008 08:01:32 +0000 (GMT) Received: from meuh.localdomain (62-2-77-204.static.cablecom.ch [62.2.77.204]) by mail.mnc.ch (Postfix) with ESMTP id 6AE6523073; Wed, 16 Jul 2008 08:01:32 +0000 (GMT) Received: by meuh.localdomain (Postfix, from userid 1000) id 4E48F18364A; Wed, 16 Jul 2008 10:01:32 +0200 (CEST) To: nalini Cc: pgsql-jdbc@postgresql.org Subject: Re: Transaction handling through java References: <5b2b89135586bc69.487de7d7@nic.in> From: Guillaume Cottenceau X-Hashcash: 1:20:080716:nalini@nic.in::CeN87vugdQDxQoy6:00001NCl X-Hashcash: 1:20:080716:pgsql-jdbc@postgresql.org::MJNiO3WFdzDjr/v8:0000000000000000000000000000000000002aWk Date: Wed, 16 Jul 2008 10:01:32 +0200 In-Reply-To: <5b2b89135586bc69.487de7d7@nic.in> (nalini@nic.in's message of "Wed\, 16 Jul 2008 12\:21\:43 +0500") Message-ID: <87bq0yw943.fsf@mnc.ch> User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200807/37 X-Sequence-Number: 18822 Hi, > I am facing the following problem. > > Our application sends a block of queries to postgres in a begin end > block. If one of the queries take a long time to finish the whole > transaction is assumed to be committed by the application even though > the query is still running . This results in failure of all subsequent > transactions. > > Although the application is programmed to catch all exceptions , it > somehow is not able to figure out that the transaction is still not > complete. I may be missing something, but it seems to me that the problem is your application wrongly assuming that queries taking a long time to finish are assumed to be already committed? -- Guillaume Cottenceau