Return-Path: Delivered-To: apmail-db-derby-user-archive@www.apache.org Received: (qmail 55399 invoked from network); 11 Feb 2011 11:52:32 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 11 Feb 2011 11:52:32 -0000 Received: (qmail 25061 invoked by uid 500); 11 Feb 2011 11:52:32 -0000 Delivered-To: apmail-db-derby-user-archive@db.apache.org Received: (qmail 24404 invoked by uid 500); 11 Feb 2011 11:52:29 -0000 Mailing-List: contact derby-user-help@db.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Reply-To: "Derby Discussion" Delivered-To: mailing list derby-user@db.apache.org Received: (qmail 24397 invoked by uid 99); 11 Feb 2011 11:52:27 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Feb 2011 11:52:27 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS,UNPARSEABLE_RELAY X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [148.87.113.121] (HELO rcsinet10.oracle.com) (148.87.113.121) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Feb 2011 11:52:19 +0000 Received: from rcsinet13.oracle.com (rcsinet13.oracle.com [148.87.113.125]) by rcsinet10.oracle.com (Switch-3.4.2/Switch-3.4.2) with ESMTP id p1BBpusZ001057 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 11 Feb 2011 11:51:57 GMT Received: from acsmt353.oracle.com (acsmt353.oracle.com [141.146.40.153]) by rcsinet13.oracle.com (Switch-3.4.2/Switch-3.4.1) with ESMTP id p1B7vnWm029362 for ; Fri, 11 Feb 2011 11:51:55 GMT Received: from abhmt018.oracle.com by acsmt354.oracle.com with ESMTP id 998273471297425019; Fri, 11 Feb 2011 03:50:19 -0800 Received: from localhost (/129.150.116.69) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 11 Feb 2011 03:50:19 -0800 From: Knut Anders Hatlen To: derby-user@db.apache.org Subject: Re: Closing connection result with exception References: <4D550918.7080106@nomagic.com> <4D551BE3.7040806@nomagic.com> Mail-Followup-To: derby-user@db.apache.org Date: Fri, 11 Feb 2011 12:50:17 +0100 In-Reply-To: <4D551BE3.7040806@nomagic.com> (Egidijus Vaisnora's message of "Fri, 11 Feb 2011 13:22:11 +0200") Message-ID: User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (usg-unix-v) MIME-Version: 1.0 Content-Type: text/plain X-Source-IP: acsmt353.oracle.com [141.146.40.153] X-Auth-Type: Internal IP X-CT-RefId: str=0001.0A090207.4D5522DC.0068:SCFMA4539814,ss=1,fgs=0 X-Virus-Checked: Checked by ClamAV on apache.org Egidijus Vaisnora writes: > I have updated derby but still the same. Issue DERBY-3806 covers > problem when ResultSet was not closed, however I am closing ResultSet, > prepared statement and then connections. What I am not doing is commit > either rollback calls - jsut because I am executing SELECT statement. > Do I need to call "commit" or "rollback" in any case before "close", > even if I am using SELECT statement and I am closing opened ResultSet > and prepared statement? Yes, a select statement executes within a transaction and may acquire locks that are not released until the transaction has finished, so read-only transactions need to be committed or rolled back too. -- Knut Anders