thomas
|
| Posted: 07/07/2002, 9:10 AM |
|
Hi there,
i have to record forms on two pages. On my first page i will create the first record in the dabase, on my second page i need to update the first record. What is the best way to transfer the record_id to the second page.
thomas
|
|
|
 |
Chris K.
|
| Posted: 07/07/2002, 11:26 AM |
|
You could use session variable to transfer this value (using CCSet/GetSession functions) or append newly created identifier to redirection string (modificating Redirect variable).
You can retrieve last inserted row identifier using mysql_insert_id() function in PHP or SELECT @@Identity SQL query in ASP/MS Access.
|
|
|
 |
thomas
|
| Posted: 07/07/2002, 10:12 PM |
|
thanx for your answer. i have freebsd, apache, php and mysql.
on the first page i insert the following code in the after insert event
$last = mysql_insert_id();
$sActionFileName .= "?mayid=".$last;
on the second page i define a input parameter variable
mayid on the field contact_id
thats all...
there are also further informations in the tips sections, keyword autoincrement
because there are two other ways. you can also tranfer the session variable or a paramter directly
thomas
|
|
|
 |
|