Thread: JDBC: Insert ID
View Single Post
Old 06-21-2004, 02:39 PM   #2 (permalink)
Belisarius
Java fanboy
 
Belisarius's Avatar
 
Join Date: Aug 2003
Posts: 1,140
Belisarius is on a distinguished road
You know, I never bothered looking up how to do this because I was able to solve my problem with an SQL query, but I think there is a way to do what you want. Use the execute(String sql, int autoGeneratedKeys) method. You can then call getGeneratedKeys(), which returns a ResultSet. Let me know if it works for you.
__________________
GitS
Belisarius is offline   Reply With Quote