January 30, 2014 at 8:31 am
For an initial load of a new Data Warehouse, if the source systems do not store historical data, is it legitimate to populate the EffectiveDate column for Type 2 SCDs with the date that the initial load is run on?
Thanks
Lempster
January 31, 2014 at 12:43 pm
I would like to know too.
In my system, I have the effective ETL load date that is used instead. That's only because if the source effective date is unknown, then my processes fail over to the last known effective date, the ETL load date.
I've been told that theory was sound, but would love to learn more.
February 12, 2014 at 12:40 pm
I would use the most recent effective date from the source system, but also try to talk to the source system DBAs to make sure there is not an Audit database out there somewhere that could have some history/audit records.
Most importantly make sure the business stakeholders know the situation as soon as possible, and manage their expectations appropriately.
February 14, 2014 at 4:25 am
sneumersky (2/12/2014)
.... but also try to talk to the source system DBAs .....
If only there were some (or even one!). 😉
I agree with your sentiment though.
February 15, 2014 at 11:52 am
If there is a foreign key referencing your table then consider whether it's important for the date/time of the referencing row to correspond to the date/time range of your effectivedate. If referential integrity within time periods is important to you then you need a strategy that supports that, e.g. populate the referencing rows and the parent rows with the same date ranges.
February 17, 2014 at 6:07 am
For this particular implementation, i can't think of a scenario where a column purely used to handle a type 2 SCD for a particular attribute would be referenced by a foreign key, but I understand what you're getting at.
Regards
Lempster
February 17, 2014 at 5:50 pm
If any of your transactions reference a date prior to the effective date on the dimension, this could get somewhat confusing.
For an initial load, I generally use a "placeholder" date of "19000101". That way it's obvious that the date doesn't have any meaning other than ensuring that the dimension entry is valid prior to any facts referencing it.
Alternatively, you could work out what the first date each dimension entry is referenced, and use those as the effective dates. That can be a lot of work (depending on the size of your fact tables) though, so unless you have a business case for why that would be necessary, I would suggest that a placeholder would be easier.
February 18, 2014 at 12:37 am
I use the placeholder as well.
Because you only just started recording history, the initial load is the representation of the "single version of facts" by the source system as it is known at that exact time.
You need to communicate clearly to the end users that all transaction data before the initial load is mapped to the initial view provided by the source system and that they need to take that into account when drawing conclusions.
Need an answer? No, you need a question
My blog at https://sqlkover.com.
MCSE Business Intelligence - Microsoft Data Platform MVP
February 18, 2014 at 5:45 am
Thanls all. I think using a placeholder makes sense so that's what I'll do. Very much agree about setting user expectations!
Regards
Lempster
Viewing 9 posts - 1 through 8 (of 8 total)
You must be logged in to reply to this topic. Login to reply