X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 183E5D1B18F for ; Fri, 18 Jun 2004 21:44:34 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 90232-01 for ; Sat, 19 Jun 2004 00:44:32 +0000 (GMT) Received: from net2.micro-automation.com (net2.micro-automation.com [64.7.141.29]) by svr1.postgresql.org (Postfix) with SMTP id E7AD8D1B1FD for ; Fri, 18 Jun 2004 21:44:26 -0300 (ADT) Received: (qmail 27441 invoked from network); 19 Jun 2004 00:44:27 -0000 Received: from dcdsl.ebox.com (HELO ?192.168.1.36?) (davec@64.7.143.116) by net2.micro-automation.com with SMTP; 19 Jun 2004 00:44:27 -0000 Subject: Re: proposal for CallableStatements to handle multiple out From: Dave Cramer Reply-To: pg@fastcrypt.com To: Oliver Jowett Cc: "pgsql-jdbc@postgresql.org" In-Reply-To: <40D386F7.3040401@opencloud.com> References: <1087582419.15586.173.camel@localhost.localdomain> <40D37653.8010302@opencloud.com> <1087602030.15607.190.camel@localhost.localdomain> <40D386F7.3040401@opencloud.com> Content-Type: text/plain Organization: Cramer Consulting Message-Id: <1087605866.15619.193.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.6 Date: Fri, 18 Jun 2004 20:44:27 -0400 Content-Transfer-Encoding: 7bit X-AntiVirus: scanned for viruses by AMaViS 0.2.1 (http://amavis.org/) X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200406/109 X-Sequence-Number: 10311 I'd like to move all of that stuff into it's own class, as the rest of my patch ends up with alot of if( instanceof CallableStatement) which I'd like to avoid by putting it all in a CallableStatement implementation. Thoughts? --dc-- On Fri, 2004-06-18 at 20:21, Oliver Jowett wrote: > Dave Cramer wrote: > > See Kris's addition. > > > > At this point however I've done some work and realized that most of the > > parsing, binding and rewriting of the queries will need to be > > encapsulated in two classes, one for regular statements, and one for > > callable statements. This will allow me to totally encapsulate the logic > > for this inside the CallableStatement implementations, instead of > > mucking up the current AbstractJdbc1Statement code. > > You might want to look at my pending patch first -- I've overhauled > modifyJdbcCall and added a method that translates between user-provided > parameter indexes and actual query parameter indexes that sounds like > it'd be useful for this case. > > -O > > > > !DSPAM:40d386ac236762102998748! > > -- Dave Cramer 519 939 0336 ICQ # 14675561