X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.225.181]) by svr1.postgresql.org (Postfix) with ESMTP id DC6E7CCBC1 for ; Fri, 18 Jul 2003 18:21:58 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (svr5.postgresql.org [64.117.225.181]) (amavisd-new, port 10024) with ESMTP id 64624-04 for ; Fri, 18 Jul 2003 18:22:18 +0000 (GMT) Received: from exchange.hq.openratings.com (unknown [141.149.165.226]) by svr1.postgresql.org (Postfix) with ESMTP id 453CFCBA17 for ; Fri, 18 Jul 2003 15:21:45 -0300 (ADT) Received: from openratings.com (cancun.hq.openratings.com [10.0.0.225]) by exchange.hq.openratings.com with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2653.13) id 38QM49GQ; Fri, 18 Jul 2003 14:22:09 -0400 Message-ID: <3F183AE0.8060204@openratings.com> Date: Fri, 18 Jul 2003 14:22:24 -0400 From: Dmitry Tkach User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20021130 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Kim Ho Cc: Fernando Nasser , Barry Lind , pgsql-jdbc-list , Dave Cramer Subject: Re: Prepared Statements References: <3F174BFF.3070704@xyth os.com> <3F1801C5.9030104@openratings.com> <3F181A81.70208@xythos.com> <3F18259C.6090503@redhat.com> <1058548037.19658.159.camel@topanga.toronto.r edhat.com> <3F183004.4010508@openratings.com> <3F1830F6.3020203@openratings.com> <1058550328.19657.168.camel@topanga.toronto.redhat.com> <3F183423.9030900@openratings.com> <1058551402.20165.177.camel@topanga.toronto.redhat.com> In-Reply-To: <1058551402.20165.177.camel@topanga.toronto.redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200307/150 X-Sequence-Number: 7534 Kim Ho wrote: >>>In any case, here is a revised version of the patch. =) Thanks for the >>>pointers. >>> >>> >>> >>I must be missing something, but I don't see any difference with the >>previous version .... >> >> >> >There is an attempt to do a: >Double.valueOf(x.toString()); > >in bindNumbers to ensure that the object's string representation is a >number. This is what you were talking about before right? > > Oh, I see... Now you end up parsing it twice in some cases (once in removeRadix(), and once again in bindNumber()) - why don't you merge those two together to save one parse? Not that I care, because I am not going to be able to use this at all (and will have to build my own driver if it ever gets in), because it breaks the existing functionality :-( The hex thing may be questionable - although, I do sympathize with people who may be using it currently, and will be forced to rewrite their app now, but, at least, they have a (relatively) simple solution (which is to take on the backend's parsing of hex numbers, and do it on the app side)... What I am concerned about is the "in" thing - select * from sometable where x in ?; setObject (1, "(1,2,3,4,5)"); that works just fine right now, and will be irreperably broken by this patch... No way I am going to rewrite all the existing code to do something like select * from sometable where x in (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?) ... and then loop through the set and set each param separately, hoping I have enough questionmarks to fit them all in :-) Dima >About breaking functionality with hex. > >I'm not sure about this, maybe we could get other opinions in >(specifically Dave and Barry). I'm not so sure that it should be >allowed. (I am not saying that it is not useful.) > >Cheers, > >Kim > >