RE: Selecting Information Just Inserted

2002-04-22 Thread Hathaway, Scott L
- From: Erik Price [mailto:[EMAIL PROTECTED]] Sent: Friday, April 19, 2002 2:40 PM To: Andrew Kuebler Cc: [EMAIL PROTECTED] Subject: Re: Selecting Information Just Inserted On Friday, April 19, 2002, at 02:10 PM, Andrew Kuebler wrote: I'm inserting data with an AUTO_INCREMENT column

Selecting Information Just Inserted

2002-04-19 Thread Andrew Kuebler
Maybe someone can help me here.. I'm inserting data with an AUTO_INCREMENT column and immediately after I need to use that new number for a corresponding record in another table. How am I able to extract that new number quickly? I could run a SELECT query after the INSERT using the MAX command,

Re: Selecting Information Just Inserted

2002-04-19 Thread Luciano Barcaro
Hi, Andrew, To get the auto_increment value, simply execute select last_insert_id() after insert statement Andrew Kuebler wrote: Maybe someone can help me here.. I'm inserting data with an AUTO_INCREMENT column and immediately after I need to use that new number for a corresponding record in

Re: Selecting Information Just Inserted

2002-04-19 Thread Erik Price
On Friday, April 19, 2002, at 02:10 PM, Andrew Kuebler wrote: I'm inserting data with an AUTO_INCREMENT column and immediately after I need to use that new number for a corresponding record in another table. How am I able to extract that new number quickly? I could run a SELECT query after

Re: Selecting Information Just Inserted

2002-04-19 Thread Paul DuBois
At 14:10 -0400 4/19/02, Andrew Kuebler wrote: Maybe someone can help me here.. I'm inserting data with an AUTO_INCREMENT column and immediately after I need to use that new number for a corresponding record in another table. How am I able to extract that new number quickly? I could run a SELECT