db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a.win...@telenet-ag.de
Subject updating autoincrement value after save
Date Fri, 06 May 2005 11:51:06 GMT
Hi torque-users,

I'm trying to get the primary key (generated by the databses using 
after saving my object, but the id of the object is 0. 

object.getId() ---> 0

If I select the object after saving it, I get the correct value.

object = ObjectPeer.doSelect(...)
object.getId() ---> 4711

Im Using Torque 3.1.1 with MySql 4.1.1.
What can I do to get the id without selecting the object again.

Thanks for your answers,

To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org

View raw message