I know that:
No, you would never store a value that could be calculated from other columns in the database. Storing calculated values is a violation of database normalization.
But what about the calculated value from the relational table? For example, amount in orders is calculated from the order_products table with the formula sum (price * qty). Should I save this value in the orders table?. Thanks.
1.4m articles
1.4m replys
5 comments
56.8k users