Results 1 to 5 of 5
  1. #1
    Join Date
    Oct 2005
    Posts
    87

    Unanswered: Need your advice

    Hello, i am building a simple db, which is very similar to northwind db, but smaller and has only "invoice" part. The main idea is to have invoice filling form, where you select client, it automatically fills his address and code, then you select product and it automatically selects price for it, calculates totals and then you can print everything. Now all these things works ok.

    But i need to have one more thing.For certain clients, certains prices are different (for each client).So i am thinking which way should i go and how should i deal with normalization things and so on.....I need to select client, and then "his" prices should appear when i select certain product.Some sort of "three-way" relationship happens...

    All i have come up with is to create in tblClients new columns for "his" prices for certain products.But if i have ~40 products that have unique prices, so i have to create 40 columns in tblClients? And how then to make these prices appeare when i select this client in my invoice form....

    The main form is from form and subform where form is single and subform is continuos (same as northwind db invoices)...

    Any ideas?

    Thanks for your help

  2. #2
    Join Date
    Feb 2004
    Location
    One Flump in One Place
    Posts
    14,912
    Hi

    Are these "client specific" prices calcuable in some way or other? Either simply, such as a client gets 10% off everything or more complicated such as certain clients get 10% off products in x group, 15% off y group etc? Or are they literally an indetirministic item cost per client?
    Testimonial:
    pootle flump
    ur codings are working excelent.

  3. #3
    Join Date
    Oct 2005
    Posts
    87
    Quote Originally Posted by pootle flump
    Hi

    Are these "client specific" prices calcuable in some way or other? Either simply, such as a client gets 10% off everything or more complicated such as certain clients get 10% off products in x group, 15% off y group etc? Or are they literally an indetirministic item cost per client?

    The second version, e.g. certain clients have certain discount % for certain products.It can be for certain group of products, or for certain specific products (there can be 1 product in 1 group so it doesn't matter actually if it is group or product....right? )

    (Actually they may have certain prices, but i can convert such "certain prices" to "certain % ", so thats not problem i guess.)


    The simpl egzample could be:

    Clients in db: ClientA, ClientB, ClientC,ClientD
    Products in db: Product1, Product2, Product 3, Product4
    Prices for products: 100, 200, 300, 400

    Exceptions: ClientD has price for product4 350 (NOT 400).
    But all other clients have price for product4 400 (default).

    Or

    Client C and ClientD has price for product4 250 and 350 respectivelly (Not 400) and all other clients have price 400 for this product. Products 1,2,3 have the same prices for all clients.
    Last edited by YZF; 01-13-06 at 07:41.

  4. #4
    Join Date
    Feb 2004
    Location
    One Flump in One Place
    Posts
    14,912
    I guess the rational for whether you store % or literals would be:

    If, in the first example, the default price for product 4 doubled, would ClientD pay 350 or 700 or indeed 650?
    Last edited by pootle flump; 01-13-06 at 07:48. Reason: Another senario....
    Testimonial:
    pootle flump
    ur codings are working excelent.

  5. #5
    Join Date
    Oct 2005
    Posts
    87
    The total price would be 700. The "350" is his price for that product.

    Another egzample:

    In other words, i could say that clientA has 20% discount for product4 , 15% discount for product3 and 0% discount for all remaining products.

    ClientB has 15% discount for product4 , 12% discount for product3 and 0% discount for all remaining products.


    Product3 and product4 are those "special" products that may have different prices for different clients.Product1 and 2 are "default" products with fixed prices.
    Last edited by YZF; 01-13-06 at 07:57.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •