Question

Is there any command or tool that can recreate the schema and fill the needed time data into the time dimension SQL Table for deployment reason?

I'm currently facing the issue that only during designing the time dimension SQL Table the wizard is populating the table, afterwards there seems to be no way to invoke the same process again.

Is there any understanding how the VS Wizard does it's work`? Maybe it's a functionality one can invoke by a script or alike?

Thanks for any help

Was it helpful?

Solution

The wizard only runs at design time, so it won't help you with regular deploys if you intend to regularly add records to the time dimension. You could simply build a stored procedure that runs in your standard ETL that automatically adds additional data rows similar to what the wizard did at design time. Alternatively, you could prepopulate a much larger period of time, use a view or named query that filters to something like WHERE DateKey < CONVERT(DATE, GETDATE()) instead of using a direct table reference, and then use the view named query as your date dimension source table. The advantage of this approach is that you could use the wizard to generate a very large time dimension and then only use what's needed in the warehouse.

OTHER TIPS

An easier solution instead of re-creating the time dimension table (if it was created on a "data-source") would be to create a second time dimension with a much larger data set and merge the records from both tables. If you re-create the time dimension then you will have to re-link all other tables/queries in your data source view as well as re-configure your other dimensions.

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