Good I wonder how I could create the invoice table and invoice detail in a system where not only are items sold. The question is the following in a business there is a restaurant and also sell items or products then how could you structure the database so you can have invoices for items or food service in a single table. I have thought about making different invoice tables one for each type of invoice or having the invoice table contain articles or the order of the restaurant service and that those fields are nullable and according to the type of invoice I pass the id of some of them.
Actually I do not know what the correct form would be.