Click here to Skip to main content
15,889,315 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
hi all pro
i have a project for my university that is a small sale system
i have a table for Transaction and one for TransactionItems (Goods within that Transaction)
am i true???????????????????
what Tables and Relations Policy Do you Recommended to me?
please help me , thanks
Posted

1 solution

The tables and their relations depend on the requirements of your project.

However in your example most likely the transaction should have a primarey key, possibly a surrogate and the transactioitem would have a foreign key column referencing the transaction table. Also it most likely would make sense to define the foreign key to cascade delete operations on transaction table to the transactionitem table.
 
Share this answer
 
Comments
daghune 1-Sep-12 5:48am    
thanks Mika
Wendelius 1-Sep-12 12:08pm    
You're welcome :)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900