Hi all,
I am quite new to the SQL Server, even though i have done DBs in uni, i havent really used them so much. any how, i need some help
I have a table with products and a table with orders. on the products table i have the product ID and the price of each product.
on the orders table the product ID is inserted and the quontity of the order. I want when ever i insert a new record of order, to automatically calculate the total cost. for example i order 10 pieces of product1, costing 10(any currency) each, so total cost would be 100!
I dont know if that is possible but i think it should, its not that difficult, is it?
I saw the "formula" option on the create table window, but i just cant get it to work.
any help?
thanks
I am quite new to the SQL Server, even though i have done DBs in uni, i havent really used them so much. any how, i need some help
I have a table with products and a table with orders. on the products table i have the product ID and the price of each product.
on the orders table the product ID is inserted and the quontity of the order. I want when ever i insert a new record of order, to automatically calculate the total cost. for example i order 10 pieces of product1, costing 10(any currency) each, so total cost would be 100!
I dont know if that is possible but i think it should, its not that difficult, is it?
I saw the "formula" option on the create table window, but i just cant get it to work.
any help?
thanks