Re: PEAR::DB and autoincrement

From: Date: Tue, 21 Mar 2006 15:13:29 +0000
Subject: Re: PEAR::DB and autoincrement
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-23367@lists.php.net to get a copy of this message
Lukas Smith scrisse in data 03/21/06 14:10:
Paolo Sala wrote:
In a mysql table I have set the property autoincrement for obtaining unique IDs for data rows. There is a way to know the ID mysql have generated after an insert sql statement executed using pear::db? Is the best solution substitute the mysql autoincrement property with pear::db sequences?
yes .. DB is now in maintaince mode, so this feature will probably never be added. if you do need it consider migrating to MDB2 which has a lastInsertID() method.
Thank you very much, I think I'll upgrade to mdb2 but first of all I need to install it. I've installed mdb2 but when I try to install the mysql driver: # pear install MDB2_Driver_mysql pear/MDB2_Driver_mysql requires PHP extension "mysql" No valid packages found install failed I'm sure I have installed mysql support in php because I can query it! Someone can help me to install mysql mdb2 driver support? Thank you very much Piviul

« previous php.pear.general (#23367) next »