Re: Another Pear::DB question

From: Date: Fri, 19 Sep 2003 20:24:08 +0000
Subject: Re: Another Pear::DB question
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-7928@lists.php.net to get a copy of this message
"Chuck Hagenbuch" <chuck@horde.org> schrieb im Newsbeitrag news:1064001346.74c7e6edbe0e3@marina.horde.org... > Quoting Jan Skopek <skopek@gmx.de>: > > > anyone knows how i can get the last-insert-id with Pear::DB? > > I am using mysql-driver. > > Don't use an abstraction layer if you want to use MySQL-specific features. (In > other words, you can't.) Thanx for the Tip, but i have to use one (project-standard). Is there no other way in ::DB getting the last-insert-id ? If not, then the only way i see is to do a "SELECT MAX(id) FROM table". thanx > > Found DB_Common::nextId. But thats not the same. > > No, but it's portable across databases. > > -chuck > > -- > Charles Hagenbuch, <chuck@horde.org> > Born right the first time.

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