CodeCharge Studio
search Register Login  

Web Reporting

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

YesSoftware Forums -> CodeCharge Studio -> General/Other

 Add record and update another table.

Print topic Send  topic

Author Message
adorni

Posts: 120
Posted: 01/30/2012, 9:16 AM

I have a form for add a new record to tha database with two columns: NUMBER and DATE
I need, when i "save" the new record, that in ahother table with columns NUMBER and DATE set the same values. Is possible? (in the second table the NUMBER exist, was save previuosly, i need that after add record, found the NUMBER in the second table and update the column "DATE"

THanks!
View profile  Send private message
ckroon

Posts: 869
Posted: 01/30/2012, 10:08 AM

In the After Insert Event I would do a Select MAX(primarykeyfield) as last from table WHERE ???

Then grab the field values WHERE primarykeyfield = last.

Then update table 2 accordingly.

_________________
Walter Kempees...you are dearly missed.
View profile  Send private message
adorni

Posts: 120
Posted: 01/30/2012, 10:15 AM

Do you have an example??? (i donīt understand php much :))
View profile  Send private message
adorni

Posts: 120
Posted: 01/30/2012, 10:34 AM

iN MY EXAMPLE, THE PRIMARY KAY IS ANOTHER column
View profile  Send private message

Add new topic Subscribe to topic   


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

PHP Reports

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

Home   |    Search   |    Members   |    Register   |    Login


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