looking for design help (or best practices) Ok so lets say I have several types of purchasable commodities &
services - Products, Services, Packages (products & services grouped
together), and Other (unkown fees and such that need to be accounted
for)
So normally.. products, services, packages, and other all get their
own table.
On a purchase though I have to store what commodities have been
bought. Currently this means I have resource_id (the product, service,
etc primary key) and then resource_type (enum to point to table
holding commodity)
This feels ackward though. Should I be doing this? Do you think there
should be a big commodities table which holds all products, services,
etc.. which then points to the separate table (likely another
resource_id, type field)? Any other ideas on this.
(by the way) It's not just the order table which needs to point to the
"commodities", I also have invoices, packing slips, taxes and other
things which all will be referencing these commodities. |