Duplicating Dimension Attributes
3 posters
Page 1 of 1
Duplicating Dimension Attributes
I have an accumulating fact table tracking the lifecycle of what we refer to as a "Case" in my organization. Each "Case" has a set of 9 specific events, for which we are tracking dates, and the measures in the fact table are the monetary values of the case at each step in the process, as it can change over time.
Two of the dimensions in the fact table are "Product" and "Company". The relationships are as follows: each "Case" is associated with a "Product" and each "Product" is sold by a particular "Company". There is a 1 -> M relationship between product and company.
The business users want to be able to analyze "Cases" by both products and companies. From what I have learned about dimensional modeling, it would seem that I should represent the relationship between products and companies only through the fact table, but I keep going back and adding "Company Name" and "Company Number" as attributes in my "Product" dimension because it makes sense to me, even though they are in the "Company" dimension. My reasoning is that if anyone wants to do any reporting or analysis on the product dimension itself, they would want the company info in there. Does anyone have any thoughts on this? Thanks
Two of the dimensions in the fact table are "Product" and "Company". The relationships are as follows: each "Case" is associated with a "Product" and each "Product" is sold by a particular "Company". There is a 1 -> M relationship between product and company.
The business users want to be able to analyze "Cases" by both products and companies. From what I have learned about dimensional modeling, it would seem that I should represent the relationship between products and companies only through the fact table, but I keep going back and adding "Company Name" and "Company Number" as attributes in my "Product" dimension because it makes sense to me, even though they are in the "Company" dimension. My reasoning is that if anyone wants to do any reporting or analysis on the product dimension itself, they would want the company info in there. Does anyone have any thoughts on this? Thanks
jimbo1580- Posts : 23
Join date : 2009-04-30
Re: Duplicating Dimension Attributes
You can do this but the query maybe complex. An analogous example for me is using a date dimension FK in another dimension where I want to be able to leverage the date dimension functionality. This is also easily accomplished by just joining on date. If you want to examine the relationship between products and cases, I would look at creating a new fact table rather than joining dimensions. Resist the urge to draw a relationship between dimensions just because you can.
BoxesAndLines- Posts : 1212
Join date : 2009-02-03
Location : USA
Re: Duplicating Dimension Attributes
I agree with B&L that an additional factless fact table containing company key and product key is a more flexible way to support product dimension reporting. While your solution of storing company name in the product is simpler, it begs the question... would the business be interested in other attributes about the company when looking at products? You then fall into a trap where you need to go back and add more company attributes to the product table. The company/product relationship table also makes life simpler when companies merge.
Similar topics
» dimension table design question for around 100 attributes and higher level calculated attributes
» Dimension Attributes and Fact attributes storing same data in multiple data marts??
» Status attributes on main dimension or as separate dimension
» How to Handle Data that serves as both a dimension and attributes of another dimension
» Attributes as part of employee dimension and/or own dimension
» Dimension Attributes and Fact attributes storing same data in multiple data marts??
» Status attributes on main dimension or as separate dimension
» How to Handle Data that serves as both a dimension and attributes of another dimension
» Attributes as part of employee dimension and/or own dimension
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum