pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Christophe Canovas <cc.ais40@wanadoo.fr>
To: pgsql-jdbc@postgresql.org
Subject: Cursors removed with commit
Date: Wed, 20 Aug 2014 15:39:12 +0200 (CEST)
Message-ID: <10564239.43.1408541952917.JavaMail.root@zimbra.cy.cassidian.net> (raw)
In-Reply-To: <28274652.41.1408541706510.JavaMail.root@zimbra.cy.cassidian.net>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-jdbc>

Hello,

I have a problem with my huge database ; using cursors (so using a transaction with noautocommit, statement with type_forward_only) make cursors removed if I update and save (commit) database values in the same transaction during the fetch loop.

Error message is : portal "C_03" doesn't exist

All is fine if the commit is done in a different transaction.

In more details, in the statement creation :
  con.createStatement(ResultSet.TYPE_FORWARD_ONLY, ResultSet.CONCUR_READ_ONLY, ResultSet.HOLD_CURSORS_OVER_COMMIT);
the last parameter seems to have no effect ... ?


Best Regards,
Christophe


-- 
Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-jdbc



view thread (7+ messages)  latest in thread

Message-ID: <10564239.43.1408541952917.JavaMail.root@zimbra.cy.cassidian.net>
Permalink:  ../10564239.43.1408541952917.JavaMail.root@zimbra.cy.cassidian.net/
Also on:    postgresql.org/message-id/10564239.43.1408541952917.JavaMail.root@zimbra.cy.cassidian.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: cc.ais40@wanadoo.fr
  Subject: Re: Cursors removed with commit
  In-Reply-To: <10564239.43.1408541952917.JavaMail.root@zimbra.cy.cassidian.net>
  References: <28274652.41.1408541706510.JavaMail.root@zimbra.cy.cassidian.net> <10564239.43.1408541952917.JavaMail.root@zimbra.cy.cassidian.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox