Received: from p1.selectacast.net (p1.selectacast.net [206.41.1.251] (may be forged)) by hub.org (8.9.3/8.9.3) with ESMTP id OAA74272 for ; Tue, 18 Apr 2000 14:29:51 -0400 (EDT) (envelope-from jks@p1.selectacast.net) Received: from selectacast.net (IDENT:jks@d1 [209.219.91.66]) by p1.selectacast.net (8.9.3/8.9.3) with ESMTP id OAA01474; Tue, 18 Apr 2000 14:28:16 -0400 Message-ID: <38FCA940.C3D36528@selectacast.net> Date: Tue, 18 Apr 2000 14:28:16 -0400 From: Joseph Shraibman Organization: Xtenit X-Mailer: Mozilla 4.72 [en] (X11; U; Linux 2.2.13 i686) X-Accept-Language: en MIME-Version: 1.0 To: Peter Mount CC: "'Guillaume Rousse'" , pgsql-interfaces@postgresql.org Subject: Re: where to close statement ? References: <1B3D5E532D18D311861A00600865478C70C4BD@exchange1.nt.maidstone.gov.uk> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Archive-Number: 200004/129 Peter Mount wrote: > Ah, forgot that bit. I put them under finally as it always gets run, > although you have to wrap them in a try{} win finally if the parent > method doesn't throw SQLException. > > Peter > The problem with that is that close() itself can throw a SQLException so you have to wrap it twice.