Suppose that every day you want to update your sales datamart by adding the information about the sales for the day before. Let's do some modifications to the jobs and transformations you did so that the job can run automatically.
In order to test the changes, you'll have to change the date for your system. Set the current date as 2009-10-02
.
Create a new transformation.
Drag to the canvas a Get system data step and fill it like here:
With a Select values step, change the metadata of both fields: As type put
String
and as format,yyyy-MM-dd
.Add a Set variables step and use the two fields to create two variables named
START_DATE
andEND_DATE
.Save the transformation in the same folder you saved the transformation that loads the fact.
Modify the job that loads the fact so that instead of executing, the transformation that takes the range of dates from the command line executes this one. The job looks like this:
Save it.