php-db | 2004071
Date: 07/15/04
- Next message: Hutchins, Richard: "RE: [PHP-DB] LAST_INSERT_ID?????"
- Previous message: NIPP, SCOTT V (SBCSI): "[PHP-DB] LAST_INSERT_ID?????"
- In reply to: NIPP, SCOTT V (SBCSI): "[PHP-DB] LAST_INSERT_ID?????"
- Next in thread: Hutchins, Richard: "RE: [PHP-DB] LAST_INSERT_ID?????"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
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)
<sn4265 <email protected>> wrote:
> 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 direct the user to a "Submitted" page. I am trying to pull the
> entry number to display for the user as a "ticket number". I would
> assume that I should use the LAST_INSERT_ID function for this.
> Unfortunately, I am getting either failures or all zeroes for this
> output.
> I can't even get this function to work in a SQL query window.
> Please help!!! I would attach code to this, but I am not sure what to
> attach.
>
-- DB_DataObject_FormBuilder - The database at your fingertips http://pear.php.net/package/DB_DataObject_FormBuilderpaperCrane --Justin Patrin--
-- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
- Next message: Hutchins, Richard: "RE: [PHP-DB] LAST_INSERT_ID?????"
- Previous message: NIPP, SCOTT V (SBCSI): "[PHP-DB] LAST_INSERT_ID?????"
- In reply to: NIPP, SCOTT V (SBCSI): "[PHP-DB] LAST_INSERT_ID?????"
- Next in thread: Hutchins, Richard: "RE: [PHP-DB] LAST_INSERT_ID?????"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

