pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Oliver Jowett <oliver@opencloud.com>
To: Thomas Hallgren <thhal@mailblocks.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: prepared statement call fails
Date: Mon, 06 Dec 2004 12:36:12 +1300
Message-ID: <41B39B6C.9020808@opencloud.com> (raw)
In-Reply-To: <thhal-07imPAseIcC4Dwrlj3jsQjacxd46QTg@mailblocks.com>
References: <d15ea14a0412051050399cd69b@mail.gmail.com>
	<41B35CC6.2030800@mailblocks.com>
	<d15ea14a04120511366efd4b9c@mail.gmail.com>
	<41B3663B.1010003@mailblocks.com>
	<thhal-0vf6OAs2HcC4EOCO9kFe0y/p7mAxh7m@mailblocks.com>
	<thhal-0vv6OAs+HcC4bv5Tf2D5MH8fUmr8Wr9@mailblocks.com>
	<41B37F31.1070205@opencloud.com>
	<41B39169.2060308@mailblocks.com>
	<thhal-07imPAseIcC4Dwrlj3jsQjacxd46QTg@mailblocks.com>

Thomas Hallgren wrote:

[...]

>> If the server makes changes that are not backwards-compatible, of 
>> course old drivers are going to break. But a) those sort of changes 
>> are rare and b) the same argument holds true for *everything* in the 
>> driver.
> 
> In this case, the server will implement something that wasn't there 
> before so there will not be any compatibility breakage. But since the 
> JDBC driver use CallableStatement for something that it wasn't intended 
> for, the special mapping it performs will become a problem now that the 
> real thing exists.

This is the whole point of using the standard escape syntax: when the 
server syntax changes, we can handle it without client applications 
needing to change.

Witness support for setFetchSize() evolving through "do nothing" through 
"use DECLARE CURSOR and FETCH" through "use V3 portals". And probably 
into "(DECLARE CURSOR WITH HOLD and V3 portals) or V4 portals" eventually.

At any rate, {?=call} support is existing functionality that people are 
using. Removing support for it because you fear that future code that 
hasn't been written yet will break it seems like a bad idea.

As I understand it, the approach being taken for "real" SPs currently is 
to extend function behaviour to support the extra bits like OUT 
parameters and returned resultsets, probably via extra SQL commands. So 
mapping a subset of {call} to what existing functions *do* support seems 
fine; we just tweak that mapping to reflect any new features on the 
server side. There doesn't seem to be a big model change in the works, 
which is all I'd be concerned about. Am I wrong here?

If you have some particular concerns about how the proposed SP syntax, 
whatever it is, is going to break the JDBC driver, by all means raise 
them.. but this seems like vague handwaving at the moment.

-O



view thread (13+ messages)  latest in thread

Message-ID: <41B39B6C.9020808@opencloud.com>
Permalink:  ../41B39B6C.9020808@opencloud.com/
Also on:    postgresql.org/message-id/41B39B6C.9020808@opencloud.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: oliver@opencloud.com, thhal@mailblocks.com
  Subject: Re: prepared statement call fails
  In-Reply-To: <41B39B6C.9020808@opencloud.com>
  References: <d15ea14a0412051050399cd69b@mail.gmail.com> <41B35CC6.2030800@mailblocks.com> <d15ea14a04120511366efd4b9c@mail.gmail.com> <41B3663B.1010003@mailblocks.com> <thhal-0vf6OAs2HcC4EOCO9kFe0y/p7mAxh7m@mailblocks.com> <thhal-0vv6OAs+HcC4bv5Tf2D5MH8fUmr8Wr9@mailblocks.com> <41B37F31.1070205@opencloud.com> <41B39169.2060308@mailblocks.com> <thhal-07imPAseIcC4Dwrlj3jsQjacxd46QTg@mailblocks.com> <41B39B6C.9020808@opencloud.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox