Skip site navigation (1) Skip section navigation (2)

Re: A basic Statement.getGeneratedKeys() implementation (patch attached)

From: Adam B <adamb(at)videx(dot)com>
To: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: A basic Statement.getGeneratedKeys() implementation (patch attached)
Date: 2009-05-01 21:06:00
Message-ID: 49FB6438.9060000@videx.com (view raw or flat)
Thread:
Lists: pgsql-jdbc
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=US-ASCII" http-equiv="Content-Type">
</head>
<body bgcolor="" text="#000000">
Kris Jurka wrote:
<blockquote cite="mid:Pine(dot)BSO(dot)4(dot)64(dot)0905011649310(dot)13271(at)leary(dot)csoft(dot)net"
 type="cite"><br>
  <br>
On Fri, 1 May 2009, Adam B wrote:
  <br>
  <br>
  <blockquote type="cite">Our webapp relies heavily on JDBC's
Statement.getGeneratedKeys()
    <br>
abstraction.&nbsp; We are investigating switching from Mysql to Postgre so I
    <br>
created a basic implementation of this feature in the 8.3-604 version
of
    <br>
the driver.&nbsp; The diff patch is attached.
    <br>
  </blockquote>
  <br>
This has some pretty severe restrictions and some more that aren't
mentioned (overriding getUpdateCount(), not using the V2 protocol which
has nothing to do with JDBC2/3).&nbsp; We've implemented generated key
support in CVS for the upcoming 8.4 release that is more robust, but
makes some other tradeoffs (returning all columns rather that just a
single key).&nbsp; Could you test this out in your application?
  <br>
</blockquote>
I'd be glad to give that a try.&nbsp; I'm all for an official implementation
as long as it's reasonably fast.&nbsp; However I probably wont be able to
get to it for about a week (vacation).<br>
<blockquote cite="mid:Pine(dot)BSO(dot)4(dot)64(dot)0905011649310(dot)13271(at)leary(dot)csoft(dot)net"
 type="cite"><br>
CVS info here:
  <br>
  <br>
<a class="moz-txt-link-freetext" href="http://jdbc.postgresql.org/development/cvs.html">http://jdbc.postgresql.org/development/cvs.html</a>
  <br>
  <br>
A thread discussing how it doesn't work for a Spring application here:
  <br>
  <br>
<a class="moz-txt-link-freetext" href="http://archives.postgresql.org//pgsql-jdbc/2009-04/threads.php#00081">http://archives.postgresql.org//pgsql-jdbc/2009-04/threads.php#00081</a>
  <br>
  <br>
Kris Jurka
  <br>
</blockquote>
<br>
<BR />
<BR />
<HR />
Videx&nbsp;Inc.&nbsp;1105&nbsp;N.&nbsp;E.&nbsp;Circle&nbsp;Blvd.&nbsp;Corvallis&nbsp;OR&nbsp;97330&nbsp;(541)&nbsp;758-0521<BR />
CONFIDENTIAL&nbsp;COMMUNICATION:&nbsp;The&nbsp;email&nbsp;message&nbsp;and&nbsp;any&nbsp;attachments&nbsp;are&nbsp;intended&nbsp;only&nbsp;for&nbsp;the&nbsp;addressee.&nbsp;&nbsp;They&nbsp;may&nbsp;be&nbsp;privileged,&nbsp;confidential,&nbsp;and&nbsp;protected&nbsp;from&nbsp;disclosure.&nbsp;If&nbsp;you&nbsp;are&nbsp;not&nbsp;the&nbsp;intended&nbsp;recipient,&nbsp;any&nbsp;dissemination,&nbsp;distribution,&nbsp;or&nbsp;copying&nbsp;is&nbsp;expressly&nbsp;prohibited.&nbsp;&nbsp;If&nbsp;you&nbsp;received&nbsp;this&nbsp;email&nbsp;message&nbsp;in&nbsp;error,&nbsp;please&nbsp;notify&nbsp;the&nbsp;sender&nbsp;immediately&nbsp;by&nbsp;replying&nbsp;to&nbsp;this&nbsp;e-mail&nbsp;message&nbsp;or&nbsp;by&nbsp;telephone<BR />
</body>
</html>




Attachment: unknown_filename
Description: text/html (2.8 KB)

In response to

pgsql-jdbc by date

Next:From: John ListerDate: 2009-05-02 13:23:43
Subject: getTiIme/Timestamp with TimeZone inconsistency
Previous:From: Kris JurkaDate: 2009-05-01 20:54:20
Subject: Re: A basic Statement.getGeneratedKeys() implementation (patch attached)

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group