Time for action – loading the fact table using a range of dates obtained from the command line
Now you will get the range of dates from the command line and load the fact table using that range:
- Create a new transformation.
- With a Get system info step that you will find in the Input category of steps, get the first two arguments from the command line and name them
date_from
anddate_to
. - By using a couple of steps, check that the arguments are not null, have the proper format (yyyy-mm-dd), and are valid dates.
- If something is wrong with the arguments, abort.
- If the arguments are valid, use a Set variables step to set two variables named
DATE_FROM
andDATE_TO
. - Save the transformation in the same folder, where you saved the transformation that loads the fact table.
- Test the transformation by providing valid and invalid arguments to see that it works as expected.
- Create a job and save it in the same folder in which you saved the job that loads the dimensions.
- Drag to the canvas a START and two...