Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Database > SQL Language
SQL Language SQL Language discussions not specific to a particular RDBMS program or vendor.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Language section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old February 22nd, 2006, 07:35 PM
Registered User
Join Date: Feb 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Help with SQL table(s) design

I am trying to create/add to our Inventory relation by allowing the database
to store information on discounts. I want to be able to define rules that
would apply to Inventory.

I have one component complete, that being the ability to define specials
such as all Inventory within a ProductLine between StartDate and EndDate
will be 20% off.
That looks like this:
Table Name = LineDiscount
Attributes are:

I want to also be able to apply rules such as the following
Buy x get y free
Buy qty x get x for $
Buy x and y get % off

I think these are similar to the more sophisticated modeling being done, but
I am struggling with how to best design the database to store the "rules" so
my application can use them.

I am hoping someone has ideas and/or experience with this type of design and
can offer some examples or other resources to help me find the solution.


Similar Threads
Thread Thread Starter Forum Replies Last Post
table design.. help please sarah lee SQL Server 2000 2 September 1st, 2006 01:35 PM
IF Statement in the SQL Design View cej2583 SQL Server 2000 6 July 17th, 2006 05:32 AM
Table Design Error? pannet1 BOOK: Expert One-on-One Access Application Development 0 April 15th, 2005 10:47 AM
database table design problems leeegglestone Access 2 August 12th, 2004 12:55 PM
Table Design Help donnapep SQL Server 2000 3 July 29th, 2004 01:13 PM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.