Question

I see there is an importance in having a row inserted and a row last updated fields in a fact table. But I could not find any standard data warehouse or a reference which says that this is a good thing to do. I am uncertain whether this is because it is a bad practice; if so why should it be so? If it is because of the data size, I see it is only 8bytes for a full date field.

Any help is greatly appreciated!!!

Was it helpful?

Solution

There's nothing talking about whether it's a good or bad practice because we include creation time and updated time only if we need them or ever will need them.

It's a "good thing to do" if you need to access those columns and a "bad thing to do" if your table will never require those columns.

OTHER TIPS

The inclusion of insert and update timestamps in your data warehouse tables allow you to be able to report from the perspective of as was and/or as is with regards to the data warehouse. These timestamps would be in addition to any timestamps that may be captured from the source.

They also make troubleshooting easier and in a worse case scenario the ability to back out a set of data from a specific run of an ETL process.

At a previous client, the data model we implemented included upwards of 6 different timestamps to provide slowly changing history, as is/ as was reporting, and source related time stamps. It made for very flexible reporting but also increased the learning curve of how to get exactly what you wanted from the table(s).

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top