When to add attribute to Dimension or Create new Dimensions
5 posters
Page 1 of 1
When to add attribute to Dimension or Create new Dimensions
Hello,
I'm new to Data Warehousing and Dimensional Modeling. We are currently in a pilot mode to start collecting some data and setting up a pilot data mart.
Luckily I found out about the Kimball Group and have started reading through their materials from the start, but currently I'm looking for a good source of examples references of how the best ways to split up / or not to split up Dimension Attributes in the model.
For example we have should an employee dimension have a department attribute or should the department attributes be in their own dimension, or is it OK to have the attributes in both?
Another example for us is Project attributes. We run medical studies and would like the slice the data by Phase and Therapeutic Area. Should those both be Dimensions, or should they both be attributes on a Studies Dimension.
Thanks in advance for any good references. Please let me know if I need to narrow the question down more (i know it is very broad), or if I'm missing something completely.
I'm new to Data Warehousing and Dimensional Modeling. We are currently in a pilot mode to start collecting some data and setting up a pilot data mart.
Luckily I found out about the Kimball Group and have started reading through their materials from the start, but currently I'm looking for a good source of examples references of how the best ways to split up / or not to split up Dimension Attributes in the model.
For example we have should an employee dimension have a department attribute or should the department attributes be in their own dimension, or is it OK to have the attributes in both?
Another example for us is Project attributes. We run medical studies and would like the slice the data by Phase and Therapeutic Area. Should those both be Dimensions, or should they both be attributes on a Studies Dimension.
Thanks in advance for any good references. Please let me know if I need to narrow the question down more (i know it is very broad), or if I'm missing something completely.
SQLGiant- Posts : 2
Join date : 2012-06-20
Re: When to add attribute to Dimension or Create new Dimensions
When you have department attributes in employee dimension or in other dimensions, handling department attributes in ETL processes will be more complex.
If you hold only department key in employee dimension, you have to take action when the department of the employee changes. If you hold some other department attributes, you have to track changes in department records while loading employee dimension. For example when the name of a department changes, you have to reflect these changes to employee dimension.
If you hold only department key in employee dimension, you have to take action when the department of the employee changes. If you hold some other department attributes, you have to track changes in department records while loading employee dimension. For example when the name of a department changes, you have to reflect these changes to employee dimension.
umutiscan- Posts : 51
Join date : 2010-11-26
Age : 44
Location : Istanbul, Turkey
Re: When to add attribute to Dimension or Create new Dimensions
Thank you for the reply! That all makes sense. I guess the question is, is it OK to have a Key to another dimension in a dimension. In the HR example that Kimball lays out in this article, he says that we can obtain the employees current state at any given time slice by querying the employee_transaction dimension, that to me would mean that it must contain a link to a department. Or is this a case for a factless fact table to link employee to department to keep that history and current relationship.
SQLGiant- Posts : 2
Join date : 2012-06-20
Re: When to add attribute to Dimension or Create new Dimensions
You should create a factless fact table instead of creating relationships between dimensions. If you need to know what employees belong to which departments and when, that's a fact! Once you start down the road of relating dimensions, you diemensional model starts to look more and more like a normalized data model.
BoxesAndLines- Posts : 1212
Join date : 2009-02-03
Location : USA
Re: When to add attribute to Dimension or Create new Dimensions
For the sake of argument here - isn't a normal fact table doing the same thing as a factless fact table in terms of keeping track of many-to-many relationships between dimensions? The only difference (from a physical layout standpoint) is that we're not always recording actual facts. Also, the use case scenarios are different.
jchernev- Posts : 14
Join date : 2011-12-08
Re: When to add attribute to Dimension or Create new Dimensions
jchernev wrote:For the sake of argument here - isn't a normal fact table doing the same thing as a factless fact table in terms of keeping track of many-to-many relationships between dimensions? The only difference (from a physical layout standpoint) is that we're not always recording actual facts. Also, the use case scenarios are different.
Yes. A fact-less fact is just a fact table without measures.
Similar topics
» Same attribute in multiple dimensions or Create new dimension?
» Composite Dimension Natural Keys - Attribute Used In Multiple Dimensions as well as Fact Tables
» Single Attribute Dimensions - why not instead write textual attribute into Fact table?
» Dimension Attribute or Fact Attribute
» Should I create one or two dimensions?
» Composite Dimension Natural Keys - Attribute Used In Multiple Dimensions as well as Fact Tables
» Single Attribute Dimensions - why not instead write textual attribute into Fact table?
» Dimension Attribute or Fact Attribute
» Should I create one or two dimensions?
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum