Kimball Forum
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Fact Table Foreign Key reference question

3 posters

Go down

Fact Table Foreign Key reference question Empty Fact Table Foreign Key reference question

Post  mru22 Wed Aug 10, 2011 4:45 pm

I have a fact table Called "Injury" I have now had to bring in additional data which includes body part and nature of the injury information related to the injury.

So and Injury can have 0,1 or more body parts. I originally was going to make a table called BodyPartInjuryNature have a foreign key from the Injury Fact table. Is that the correct way or would there be a better option for design ?

Thank you,


mru22

Posts : 34
Join date : 2011-06-14

Back to top Go down

Fact Table Foreign Key reference question Empty Re: Fact Table Foreign Key reference question

Post  hang Sat Aug 13, 2011 5:38 pm

I don't think you can have body parts FK in the injury fact table which is at injury level and body part is a multivalued dimension. I would create a bridge table that holds both FKs so that you are able to drill down from injury to body parts

hang

Posts : 528
Join date : 2010-05-07
Location : Brisbane, Australia

Back to top Go down

Fact Table Foreign Key reference question Empty Re: Fact Table Foreign Key reference question

Post  cjrinpdx Mon Aug 15, 2011 3:10 pm

The grain is different. Your current fact table "Injury" is one row per injury. Your new fact table would be one row per injury and body part. Your new fact table could be a factless fact table where you just pull in the related dimensions (body part, person, injury nature).

cjrinpdx

Posts : 51
Join date : 2011-07-14
Location : Portland, OR

Back to top Go down

Fact Table Foreign Key reference question Empty Re: Fact Table Foreign Key reference question

Post  Sponsored content


Sponsored content


Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum