I'm attempting to structure a database for optimal use. However I have no clue steps to make which happen. Here's what i'll have
A category that will have numerous items along with a count for every on of individuals items
Restaurants would be the category and also the items would be the computer, check out and every one of these items includes a count so perhaps you will see 2 cash registers and three personal computers and so forth. Another catagory may well be a bar, that might or might possibly not have exactly the same items. Then your user has a choice of selecting a couple restarant package that might possess a discount rate to get all of the items.
I simply need to structure the ERB basically could possibly get outside assistance, Thanks
- PRODUCT_ID (primary key)
- CATEGORY_ID (primary key)
- PRODUCT_ID (primary key, foreign answer to
- CATEGORY_ID (primary key, foreign answer to
This'll permit you to connect an item to several category, although not allow replicates.
- <address info>
Establishment is really a lengthy word, I simply tried on the extender here for instance. You can easily change it with location/loc, venue, or other things the thing is fit.
For the way the information changes, I added the discount table, thinking there'd differ discount rates for variant quantity of items bought.
Example: 80% of items bought would yield a 5% discount, but 100% of purchases might yield a tenPercent discount.