I need to insert a new record into a MySQL table which has an auto_increment
field Ref as the primary index. When I have inserted the new record, I need
to get the new Ref value in order to name some files to relate to the
record. At the moment I have to do a SELECT command and search for
On Saturday, Feb 4, 2006, at 07:22 America/Los_Angeles, Colin Davis
wrote:
I need to insert a new record into a MySQL table which has an
auto_increment
field Ref as the primary index. When I have inserted the new record,
I need
to get the new Ref value in order to name some files to
Thank you, that is perfect.
Regards
Colin Davis
http://www.ukpages.org
Johan Martin [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
http://www.php.net/manual/en/function.mysql-insert-id.php
This will give you the record id of the last record inserted (or created).
Johan Martin
3 matches
Mail list logo