At 12:21 +0000 12/18/02, Jeff Snoxell wrote:
>I'm adding records to a db using the Perl DBI. Subsequent to adding
>a record I need to know the value of the auto-incrementing 'Ref'
>field so that I can place a copy of the relavent details into a log
>I could query for the "LAST_INSERT_ID" but what if another process
>has added another record in the interim?
>Is this a job for table locking?
No, it's probably more of a job for reading the section on LAST_INSERT_ID()
in the manual again, particularly the part about "cannot be changed by
another client." :-)