Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 2A3061337B84 for ; Thu, 17 Feb 2011 07:44:43 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 24614-01; Thu, 17 Feb 2011 11:44:34 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from tremor.opencloud.co.nz (tremor.opencloud.co.nz [131.203.101.230]) by mail.postgresql.org (Postfix) with ESMTP id 6DC6E1337B90; Thu, 17 Feb 2011 07:44:32 -0400 (AST) Received: from 121-98-80-66.bitstream.orcon.net.nz ([121.98.80.66] helo=[192.168.1.2]) by tremor.opencloud.co.nz with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1Pq2HY-0003iP-H3; Fri, 18 Feb 2011 00:44:24 +1300 Message-ID: <4D5D0A07.80706@opencloud.com> Date: Fri, 18 Feb 2011 00:44:07 +1300 From: Oliver Jowett User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.13) Gecko/20101208 Thunderbird/3.1.7 MIME-Version: 1.0 To: rsmogura CC: Florian Pflug , Tom Lane , Robert Haas , Lukas Eder , pgsql-jdbc@postgresql.org, pgsql-hackers@postgresql.org Subject: Re: Fwd: [JDBC] Weird issues when reading UDT from stored function References: <4D5BBD1A.7010005@opencloud.com> <4D5BC65D.8070507@opencloud.com> <24907.1297869823@sss.pgh.pa.us> <4D5C6876.7060805@opencloud.com> <4D5CF52B.9020707@opencloud.com> <4D5D012E.8030707@opencloud.com> <90b9defedf07d3c3732025d140897b57@mail.softperience.eu > In-Reply-To: <90b9defedf07d3c3732025d140897b57@mail.softperience.eu> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-5 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201102/1658 X-Sequence-Number: 182447 On 18/02/11 00:37, rsmogura wrote: > On Fri, 18 Feb 2011 00:06:22 +1300, Oliver Jowett wrote: >> On 17/02/11 23:18, rsmogura wrote: >>> Yes, but driver checks number of declared out parameters and number of >>> resulted parameters (even check types of those), to prevent programming >>> errors. >> >> And..? >> >> Oliver > > And it will throw exception when result will income. If you will remove > this then you will lose check against programming errors, when number of > expected parameters is different that number of actual parameters. Bear > in mind that you will get result set of 6 columns, but only 1 is > expected. I think you can't determine what should be returned and how to > fix result without signature. You've completely missed the point. I am not suggesting we change those checks at all. I am suggesting we change how the JDBC driver translates call escapes to queries so that for N OUT parameters, we always get exactly N result columns, without depending on the datatypes of the parameters in any way. Oliver