I am not sure if this can be done. I have 2 tables - One is a "Product" table and one is an "order_product" table, I have a field "Quantity" in "Order_product" and a field "Price" in the "Product" I would like these two values to be multiplied and then the result to be input into a field called "Total" which is in the "Order_Product" table. I have already created a query which does this but would like the table to function like this if possible. Thanks for your help
Asked
Active
Viewed 573 times
0
-
Tables don't function like that. You can't put an expression that refers to other columns/tables in a column. – nicomp Apr 18 '18 at 11:48
-
Even if you could, you wouldn't. Queries are - as you already have found out - for such purposes. – Gustav Apr 18 '18 at 13:17
-
Saving calcs (data dependent on other data) is usually unnecessary. Build query that joins tables to retrieve related info. If Price is subject to change over time then you have to decide whether to save that price to order_product table or create new record for new price and deactivate the old record and restrict comboboxes not to offer the inactive record. Saving the Price (or the calculated Total) will require code (macro or VBA) but is really simple. Include the Price as a column of a combobox then code can reference that column by its index. – June7 Apr 28 '18 at 21:33