Junction Table

  • Thread starter Thread starter Christo Yssel
  • Start date Start date
C

Christo Yssel

Hi,
I need to confirm that I have done this correctly:

I have the following tables:
Suppliers
SuppliersID (pk)

Products
ProductID (pk)
SupllierID (fk)
UnitPrice (from supplier)
one-to-may relationship between products and suppliers
Every supplier has many products but products have only one supplier

Clients
ClientID (pk)

Here I have a slighty different problem. Every Client has a unique price for
every product, which means every Client is charged a different price for the
same product

I am using the following junction table to solve this many-to-many
relationship between product and client

ClientProductPrices
ClientID
ProductID {Composite pk)
ClientProductPrice

Thanks
Christo
 
What you've got looks correct. However, are you going to need to worry about
history? (What price did this customer pay for that product on such and such
a date?)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top