Copy calculated field into 2nd table

smyeong

Registered User.
Local time
Today, 20:55
Joined
Mar 17, 2003
Messages
27
Dear all,

It's about the copy calculated field from a form into another table. I know it 's not recommended becoz of denormalization. In fact, i need to learn it anyhow.

Someone taught me to use update query :
Balance_afterupdate()
If not isnull(balance) then
docmd.runSQL "put my sql here"
End If

Eventually, i don know how to write the query ....All i wanted is update the balance field in location table when the location field is match to the location in the form ..
Below is something i 'd guess

Update tbl_location set balance = ???? where me.location = location.tbl_location

YEONG,
Best Regards
 
The reason that no one has answered your question after all these hours is that no one wants to put the gun in your hands. You know it is "wrong" but you still want to do it. I will give you a hint, an update query here is likely to be problematic. Use DAO or ADO, which ever you are more comfortable with. Look up the update method in VBA help (open help from the VBA window) to get sample code.
 
Thanks for your concern

Thanks anyway. What i did can lead to denormalization. Trust me i would use it wisely.

Thanks again
 

Users who are viewing this thread

Back
Top Bottom