Re: getGeneratedKeys() support?

From: Andrew Lazarus <drlaz(at)attglobal(dot)net>
To: Benjamin Shive <bshive(at)comcast(dot)net>, "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org>
Subject: Re: getGeneratedKeys() support?
Date: 2007-08-30 21:32:17
Message-ID: 462642779.20070830143217@attglobal.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

The current JDBC driver supports the RETURNING clause and it does
exactly what someone would want.

ResultSet rs = statement.executeQuery("INSERT INTO z(myField) VALUES(0)
RETURNING keyName") ;
int key = rs.getInt(1);

Hallelujah

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Albe Laurenz 2007-08-31 08:22:15 Re: Retrieving Columns by table-alias
Previous Message Dominik Bruhn 2007-08-30 20:44:38 Retrieving Columns by table-alias