Hi Bill, we could manage at least the generated keys, using Statement#getGeneratedKeys()[1], requiring a non null ResultSetHandler. To not break APIs backward compatibility, that could be a new set of APIs...
WDYT? best, -Simo [1] http://docs.oracle.com/javase/6/docs/api/java/sql/Statement.html#getGeneratedKeys() http://people.apache.org/~simonetripodi/ http://simonetripodi.livejournal.com/ http://twitter.com/simonetripodi http://www.99soft.org/ On Sun, Jan 29, 2012 at 5:05 PM, William Speirs <[email protected]> wrote: > That is a question more specific to the database you're using, than > DBUtils. For some databases this means writing a stored procedure which > performs the insert, and then a special select to get the primary key. You > can of course use DBUtils to call this stored proc and read the primary key. > > Hope this helps... > > Bill- > > On Sun, Jan 29, 2012 at 9:44 AM, Moandji Ezana <[email protected]> wrote: > >> Is it possible with the current API to do an insert and get back the >> generated primary key, rather than the number of affected rows? >> >> Best regards, >> >> Moandji >> --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
