wondering if this can be done (Full Version)

All Forums >> [Web Development] >> ASP and Database



Message


charlie df -> wondering if this can be done (8/15/2001 14:48:00)

I would like to use one form to update 2 tables in a database, one alwasy gets updated, and the other gets update if certain condtionons are met.

Table 1: updated no matter what, adding a new record to the table.
Table 2: Would be updated by using information ( a comparison of 2 numbers) form Table 2 to determine if a condition is met. If the condition is met then one of the 2 numbers would then be updated.

I have just started to learn VBScript, and think I can put together the If..Then..Else script, but not sure about submitting one form to do the adding and updating of records.

Thanks for any help anyone can offer me.





Spooky -> RE: wondering if this can be done (8/15/2001 16:36:00)

Assuming you have a working database update, you would do something like :

<%
Open.Database connection

' Execute(Do database #1 code)

If Comparison a <> B then

' Execute(Do update # 2 code)

End if
Close.Database connection

------------------
§þððk¥
"I am Spooky of Borg. Prepare to be assimilated, babycakes!"
Subscribe to OutFront News
Database / DRW Q & A
The Spooky Login!
VP-ASP Shopping cart





charlie df -> RE: wondering if this can be done (8/15/2001 16:48:00)

Thanks spooky, I'm going to give it a try. Like I said, i am just starting out in VBScript, so I will try to get my if then else statements right, if I have any problem I'll be back. Just glad to know that it's possible and I am not wasting my time.




Page: [1]

Valid CSS!




Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI
0.109375