User Tools

Site Tools


transformations:calendar

CALENDAR

Category: Create / Generate


Description

This action creates a table with a list of dates for a specified date range. One row corresponds to one day. Start and end dates can be defined as an absolute or relative date, or defined by a parameter.


Use cases

Use this action when you need to create a dataset of date-based values (days, weeks, weekdays, months, or years) to be used downstream.


Action settings

From

Setting Description
Date*Select an absolute starting date value using the date-picker.
TodaySet the starting date as today's date (relative).
# days back*If the To setting is either an absolute date or Today, this sets the starting time as the number of days prior to the To date.
If To is set to # of days ahead, this setting will be disabled.

* Setting can be specified using a parameter.

To

Setting Description
Date*Select an absolute ending date value using the date-picker.
TodaySet the ending date as today's date (relative).
# days ahead*If the From setting is either an absolute date or Today, this sets the ending time as the number of days after the From date.
If From is set to # of days behind, this setting will be disabled.

* Setting can be specified using a parameter.

Columns

These options define the columns that will be included in the generated dataset. At least one option must be selected. All options will generate a value for each date in the specified date range.

Setting Description
Date as numberWhen selected, dates are generated as number values with a format of dd-MMM-yyyy (e.g. 10-Mar-2021).
Formatted dateGenerates text-based date values using the selected format.
Options: d/M/yyyy (e.g. 5/3/21), yyyy/MM/dd (e.g. 2021/03/05).
YearGeneates a list of year values in yyyy format (e.g. 2021).
Month numberGenerates a list of numeric month numbers (1-12).
Month nameGenerates a list of abbreviated month names (e.g. Jan, Feb, Mar).
DayGenerates a list of day numbers.
Day of week (number)Generates a list of weekday numbers from 1 (Sunday) to 7 (Saturday).
Day of week (name)Generates a list of weekday full names (e.g. "Sunday").
Weekend flagGenerates a list of Boolean values (TRUE/FALSE) defining whether the date falls on a weekend day
(Saturday or Sunday = TRUE), or not (FALSE).


Examples

For the date "March 20, 2021" the following settings will produce the following output values:

SettingOutput
Date as number20-Mar-2021
Formatted date(yyyy/MM/dd) 2021/03/20, (d/M/yy) 20/3/21
Year2021
Month number3
Month nameMar
Day20
Day of week (number)7
Day of week (name)Saturday
Weekend flagTRUE


See also

transformations/calendar.txt · Last modified: 2021/04/02 04:33 by dmitry

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki