CodeCharge Studio
search Register Login  

Visual Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 transfer the current record ID to the next form

Print topic Send  topic

Author Message
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

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

MS Access to Web

Convert MS Access to Web.
Join thousands of Web developers who build Web applications with minimal coding.

CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.