Add missing dates
Last updated
Was this helpful?
Last updated
Was this helpful?
The Add missing dates step allows to add missing dates as new rows in a dates column. Exhaustive dates will range between the minimum and maximum date found in the dataset (or in each group if a group by logic is applied - see thereafter).
Added rows will be set to null in columns not referenced in the step configuration. You can use a “Fill null values” step afterwards if you need to fill those nulls.
You should make sure to use a group by logic if you want to add missing dates in independent groups of rows (e.g. you may need to add missing rows for every country found in a “COUNTRY” column). And you should ensure that every date is unique in every group of rows at the specified granularity, else you may get inconsistent results. You can specify “group by” columns in the Group by
parameter as shown below. Please see example 2 below for illustration.
Dates column
column(string)*: the date column (must be of type date) with missing dates
Dates granularity
(string)*: the granularity of the date column (day, month or year)
(Optional) Group by
column(array) (optional) : Use this option if you need to perform add missing dates in independent groups of rows. You should make sure that every date is unique inside each and every group. See example 2 below for illustration.
Input
Configuration
Output
The date of the January 6th, 2018
has been added to the dataset.