Re: normalization question

From: Brian Selzer <brian_at_selzer-software.com>
Date: Wed, 29 Apr 2009 22:44:29 -0400
Message-ID: <Cm8Kl.15770$pr6.6310_at_flpi149.ffdc.sbc.com>


> "toby" <toby_at_telegraphics.com.au> wrote in message
> news:a58ad58a-c46b-45e2-9f39-b5082b78a73e_at_z16g2000prd.googlegroups.com...
> On Apr 28, 5:10 am, "Matko" <mkl..._at_foi.hr> wrote:
> > ItemID can't be primary key because its value in every entry is not
> > unique
> > ;)
>
> Are you sure? It seems to me that this would correspond to the
> constraint that an item can be in only one box.
>

Where did you come up with that requirement? Rule 3 states that items can be sent once from /each/ vendor to /each/ customer, not once from /any one/ vendor to /any one/ customer. This means that item1 could be sent in a box from vendor1 to customer1 and that item1 could be sent in a different box from vendor1 to customer2.

> >
> > Matko
> >
> > "toby" <t..._at_telegraphics.com.au> wrote in message
> >
> > news:9537eaf6-4d8a-46a4-a248-b625465034c7_at_y6g2000prf.googlegroups.com...
> > On Apr 27, 4:11 pm, myotheraccount <levt..._at_yahoo.com> wrote:
> >
> > > That's similar to my first proposed solution, but, like that solution,
> > > does not enforce rule #3. For example:
> > > R1
> > > BoxID, CustomerID, VendorID
> > > 1, 1, 1
> > > 2, 1, 1
> >
> > > R2
> > > BoxID, ItemID
> > > 1, 1
> > > 2, 1
> >
> > > The keys will allow this, but it violates Rule #3
> >
> > What if the key on R2 is {ItemID} alone?
Received on Wed Apr 29 2009 - 21:44:29 CDT

Original text of this message