the query succeeds, return
> the id of the new event
> }
>
> return $evNew;
>
>
> Works like a charm.
>
> Rich
>
>
>
>
> > -Original Message-
> > From: NIPP, SCOTT V (SBCSI) [mailto:[EMAIL PROTECTED]
L PROTECTED]
> Sent: Thursday, July 15, 2004 4:17 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP-DB] LAST_INSERT_ID?
>
>
> OK. I know that a BUNCH of people have had this question, and I
> have read numerous Google threads on this, but nothing really seems to
> point ou
Try the PHP funciton mysql_insert_id().
http://us3.php.net/manual/en/function.mysql-insert-id.php
On Thu, 15 Jul 2004 15:16:44 -0500, NIPP, SCOTT V (SBCSI)
<[EMAIL PROTECTED]> wrote:
> OK. I know that a BUNCH of people have had this question, and I
> have read numerous Google threads on
OK. I know that a BUNCH of people have had this question, and I
have read numerous Google threads on this, but nothing really seems to
point out the resolution... I have a table with the Primary Key as an
auto_increment field. Once I insert a new row of data into the table I
want to dire
I mean:
mysql_insert_id()
-Original Message-
From: Rick Emery [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 21, 2002 2:28 PM
To: 'Morten Nielsen'; [EMAIL PROTECTED]
Subject: RE: [PHP-DB] LAST_INSERT_ID()
use mysql_last_id()
-Original Message-
From: Mort
use mysql_last_id()
-Original Message-
From: Morten Nielsen [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 21, 2002 2:30 PM
To: [EMAIL PROTECTED]
Subject: [PHP-DB] LAST_INSERT_ID()
Hi,
In the PHP manual under the function mysql_insert_id() function they have
the following line:
The
Hi,
In the PHP manual under the function mysql_insert_id() function they have
the following line:
The value of the MySQL SQL function LAST_INSERT_ID() always contains the
most recently generated AUTO_INCREMENT value, and is not reset between
queries.
How do I get to use the function LAST_INSERT_