Bug #18409 | getGeneratedKeys(String columnName) only works when columnName=="GENERATED_KEY" | ||
---|---|---|---|
Submitted: | 21 Mar 2006 23:50 | Modified: | 11 Nov 2009 2:36 |
Reporter: | Yee Tham | Email Updates: | |
Status: | Won't fix | Impact on me: | |
Category: | Connector / J | Severity: | S2 (Serious) |
Version: | 3.1.12 | OS: | Windows (Windows XP) |
Assigned to: | CPU Architecture: | Any |
[21 Mar 2006 23:50]
Yee Tham
[22 Mar 2006 18:44]
Mark Matthews
You shouldn't retrieve these columns by name. Only by index, since there can only ever be one column with MySQL and auto_increments that returns value(s) that can be exposed by Statement.getGeneratedKeys(). Currently the MySQL server doesn't return information directly that would make the ability to retrieve these columns by name in an efficient manner possible, which is why I'm marking this as "to be fixed later", since we can, once the server returns the information in a way that the driver can use.