[MonetDB-users] primary key retrieval
Hello, How do I retrieve the primary key id value after inserting something new into the database ? I am writing a simple Java app. (using JDBC) and would like to get this info back into my program. Thanks for any help! Regards Marcus
On Dec 3, 2007 6:48 AM, Lange Marcus
Hello,
How do I retrieve the primary key id value after inserting something new into the database ?
Hey Marcus, I had a similar question using python a few days back. The subject was "python cursor missing lastrowid attribute?" That might help. The basic answer is that this is not supported (due to concurrency issues). The workaround is to pregenerate PKs using sequences.
I am writing a simple Java app. (using JDBC) and would like to get this info back into my program.
Thanks for any help!
Good luck -matt
Hello,
How do I retrieve the primary key id value after inserting something new into the database ?
Hey Marcus, I had a similar question using python a few days back. The subject was "python cursor missing lastrowid attribute?" That might help.
The basic answer is that this is not supported (due to concurrency issues). The workaround is to pregenerate PKs using sequences.
Ok, I will have a look at that thread. Thanks! /Marcus
participants (2)
-
Lange Marcus
-
m h