I am having difficulty representing additional charges in an invoice. I understand how to represent the association between an invoice and individual items in that invoice with the use of a
invoice_item table, however, there are charges that I want to include to an invoice which are not orders or products. For example, I might want to include an ad-hoc licence fee or an additional administration fees or similar.
What I have so far looks like this:
invoice ============ PK uid FK cust_id date_created status ... invoice_line ============ FK invoice_id FK order_id ... order ============ PK uid FK cust_id date_created status order_line ============ FK order_id FK product_id actual_price quantity product ============ PK uid name desc
Now, the above mentioned additional charges cannot really be represented as products here, nor are they associated to any specific order. It should be on a level similar to
order, in the sense that there might be a number of those additional charges connected to each invoice, there might in fact be such charges even in cases where there were no orders placed whatsoever within the invoice time period.
What is the recommended way to represent such additional charges in my invoice/invoice_item table?