Updating a third table

  • Thread starter Thread starter Joyce
  • Start date Start date
J

Joyce

Hi, I have learned how to successfully add, modify and update both
tables in a master/detail form such as Customers and Orders.

What I am having trouble with now is how to update the Qty field in a
third table, Products, as we add lines to the child form. That is each
row should subtract the qty amount from that item in the Products
table.

Any suggestions or articles to point to?

Thanks,
--Joyce Perry
 
Generally, most approach this problem with a SP. This deals with the entire
"update" issue--dealing with several tables in a single operation.

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
INETA Speaker
www.betav.com/blog/billva
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
 
Joyce said:
Hi, I have learned how to successfully add, modify and update both
tables in a master/detail form such as Customers and Orders.

What I am having trouble with now is how to update the Qty field in a
third table, Products, as we add lines to the child form. That is each
row should subtract the qty amount from that item in the Products
table.

Any suggestions or articles to point to?

--Joyce, one thing you can do is use the Expression property of the
dataColumn in the child/grandchild table to have it computed on the fly.
This has the benefit of being more performant and updating the value whenver
anything is changed locally. This should help
http://www.knowdotnet.com/articles/expressions.html
http://msdn.microsoft.com/library/d...fsystemdatadatacolumnclassexpressiontopic.asp
 
William, thank you so much! The Expression property is exactly what I
was looking for, and your articles - fantastic!
--Joyce Perry
 
Back
Top