----- Original Message -----
From: Kenn Murrah <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, August 17, 2001 1:17 AM
Subject: [PHP-DB] determining the value of an auto-incremented field (mysql)
[snip]
> Having done so, how can I immediately determine the value of order_number
> for this entry, i.e. the auto-incremented value assigned by MySQL?
Use mysql_insert_id(), it returns the ID generated for an AUTO_INCREMENT
column by the previous INSERT query.
regards
--
Jason Wong
Gremlins Associates
www.gremlins.com.hk
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]