I am coding a fast food system but I am having trouble at making the database logic. The business is small so the database shouldn't be too complex. They sell burgers but they want to make their hamburgers combos like mcdonalds does.
For example Combo #1 includes:
- 1 deluxe burger
- 1 Ice cream
- 1 pepsi
- and so on...
I want to store all Combos in the Food_Combos table with its detail inside in Detail_Combo . Product table are the products like Ice creams, coke, French fries, etc, that will be inside Detail_Combo .
When Combos are done... I can make a sale in a POS layout.
This is my database logic:
But the problem I am facing is that what if a customer wants to buy a single burger? ( not a combo ), I do not know how to make relationships because Food_Combos is liked to Detail_Sales.
How do I achieve this? Do I have to link Product to Detail_Sales too?