Hi, I am using Yii2 basic application template.
I have two tables with following table structure:
- OfferingId - Primary key
- OfferingDetailsid - Primary key
- OfferingId - Foreign key
The scenario is One offering has many offering details for eg,
Now the situation is I want to calculate all the amounts and store the sum as Final amount in some field. So where should I add third coumn in second table or should I create another table which stores the OfferingId and the final amount.