29 Sep
2005
29 Sep
'05
9:35 a.m.
On Thu, Sep 29, 2005 at 02:12:20AM +0200, Gerhard Killesreiter wrote:
On Thu, 29 Sep 2005, Karoly Negyesi wrote:
I think we should use autoincrement/serial and have a db_last_id function (mysql_insert_id, select currval, lastInsertId in PDO etc.). This would make Drupal code actually shorter and simpler (a very little bit).
I think that I do now recall why we are looking up the next ID first: If we use mysql_insert_id we risk not getting the right ID.
See here for some warnings: http://de.php.net/manual/en/function.mysql-insert-id.php
We do not: http://dev.mysql.com/doc/mysql/en/getting-unique-id.html http://dev.mysql.com/doc/mysql/en/information-functions.html -- Piotrek irc: #debian.pl Mors Drosophilis melanogastribus!