Unix Technical Forum

BUG #1988: keygen not implemented

This is a discussion on BUG #1988: keygen not implemented within the pgsql Bugs forums, part of the PostgreSQL category; --> The following bug has been logged online: Bug reference: 1988 Logged by: Mike Clements Email address: mikec@actional.com PostgreSQL version: ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Bugs

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-10-2008, 10:21 AM
Mike Clements
 
Posts: n/a
Default BUG #1988: keygen not implemented


The following bug has been logged online:

Bug reference: 1988
Logged by: Mike Clements
Email address: mikec@actional.com
PostgreSQL version: 8.0.3
Operating system: WinXP
Description: keygen not implemented
Details:

Create a table with an integer primary key using a sequence to automatically
assign values.
Connect to the database with a JDBC client.
Insert a row into the table using:
Connection.prepareStatement(sql, Statement.RETURN_GENERATED_KEYS);
The driver throws an exception saying this method is not yet implemented.
What it should do is create the prepared statement so when you execute it,
the returned ResultSet has the generated primary key.

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo@postgresql.org so that your
message can get through to the mailing list cleanly

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-10-2008, 10:21 AM
Oliver Jowett
 
Posts: n/a
Default Re: BUG #1988: keygen not implemented

Mike Clements wrote:

> Insert a row into the table using:
> Connection.prepareStatement(sql, Statement.RETURN_GENERATED_KEYS);
> The driver throws an exception saying this method is not yet implemented.


This is an optional part of the JDBC spec, and the driver doesn't claim
to support it in the metadata it provides
(DatabaseMetaData.supportsGetGeneratedKeys() returns false).

> What it should do is create the prepared statement so when you execute it,
> the returned ResultSet has the generated primary key.


Unfortunately this requires functionality in the backend that does not
yet exist (support for "INSERT .. RETURNING ...", or similar).

-O

---------------------------(end of broadcast)---------------------------
TIP 5: don't forget to increase your free space map settings

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 11:45 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com