Help Centre

Date Output
Introducing the new Date Output operation
The Date Output operation supersedes the legacy script operations Year Quarter and Extract Date. These operations will soon be deprecated so they can no longer be added to a pipeline. They will continue to work in existing pipelines. Updating existing pipelines to remove legacy date operations is advised.

In this section

About Date Output

Add a Date Output operation

To add a Date Output operation to your pipeline, open the ‘Add Operation’ popup and go to the category ‘Dates’. Select ‘Date Output’.

Reformat dates for use outside Quantemplate

The Date Output operation converts dates from Quantemplate’s standard format (Basic ISO
yyyyddmm
) to other formats for use in downstream systems, such as for a data warehouse or risk model.
Once dates have been reformatted in Date Output they will be treated as text and can no longer be used in date functions in Calculate. This operation should therefore be used after all required date calculations have been performed.

Valid dates

All values going into the Date Output operation must either be valid dates in Basic ISO
yyyyddmm
format, or blanks Any other values will cause the pipeline run to fail. If using Date Output, it is strongly recommended to also use a Date Cleanse operation on your input data to validate, cleanse and convert all incoming dates.
Learn more about Working with dates in Quantemplate.

Date Output workspace

Input columns

Define groups of input columns which share common settings for output format and output column.
Learn more ↓

Input date format

Define the date format the output values will be changed to, for example changing to
dd/mm/yyyy
or
yyyy-Qq
. Dates reformatted by Date Output will be treated as text by Quantemplate, so will not be compatible with date functions in Calculate.
Learn more ↓

Output columns

Set the output data to overwrite the source column, or write to a new column.
Learn more ↓

Operation name

Click to edit the operation name and description.

Search

Search column names. Matching results in the Input Columns and Output Columns are highlighted.

Define groups of input columns

To use Date Output, first add groups of input columns which share common settings for the output date format and output column.

Example

Input columns
Output format
Output column settings
Cancellation date cleansed
Claim date cleansed
Closed date cleansed
Incurred date cleansed
Notification date cleansed
Full US /  
mm/dd/yyyy
Overwrite original
Reporting date cleansed
Year-quarter  
yyyy-Qq
New column: Reporting quarter
Tip
To quickly add a large number of columns, either:
  • Use the ‘Add all columns’ option then delete the columns which do not contain dates.
  • Type a word into the search field to reveal the ‘Add column names containing’ option. For instance, add all the column names containing the word ‘date’.
Note that if new date columns are subsequently added upstream of the Date Output operation, the operation will need to be manually updated to include the new columns.

Set the output date format

To select an output date format, click in the ‘Reformat as text’ column and select from the range of commonly used formats. These formats can be used to specify slash
/
or dash
-
separators.
Input value
Basic ISO Date
Output format
Output value
Text
20120629
Full /
dd/mm/yyyy
29/06/2012
20120629
Full US /
mm/dd/yyyy
06/29/2012
20120629
Full -
dd-mm-yyyy
29-06-2012
20120629
Full US -
mm-dd-yyyy
06-29-2012
20120629
Full ISO
yyyy-mm-dd
2012-06-29
20120629
Year-month
yyyy-mm
2012-06
20120629
Year-quarter
yyyy-Qq
2012-Q2
20120629
Day
d
29
20120629
Month
m
6
20120629
Year
yyyy
2012
 
(blank)
Full /
dd/mm/yyyy
(blank)
29 June 2012
Full /
dd/mm/yyyy
Run failed

Custom date formats

To define a specific date format that is not included in the list of preset formats, click on the ‘Custom date format’ option. Select the desired date components from the suggestion list.
Custom formats in Date Output can be configured with any number or combination of supported components.
Custom formats can be copied and pasted between input groups within Date Output operations. Click the ‘Copy’ button in the custom format field, navigate to the custom format field in another input group and use
cmd/ctrl+v
to paste.

Set the output column

By default, the reformatted dates will overwrite the data in the original column. To write the data to a new column, click in the output column selector and select ‘New column’, then enter a column name. Quantemplate will warn if a new column name duplicates an existing output column name within the operation, which would result in that column being overwritten.
When configuring the output column for a group of input columns, a suffix can be defined. New columns will take the original column name plus the suffix. The default suffix is ‘_Output’.
Input columns
Overwrite / New Column
Output columns
Cancellation date cleansed
Overwrite
Cancellation date cleansed
Reporting date cleansed
New column: Reporting quarter
Reporting date cleansed
Reporting quarter
Claim date cleansed
Closed date cleansed
Incurred date cleansed
Notification date cleansed
New column: Original name_Output
Claim date cleansed
Closed date cleansed
Incurred date cleansed
Notification date cleansed
Claim date cleansed_Output
Closed date cleansed_Output
Incurred date cleansed_Output
Notification date cleansed_Output
New columns are created at the right edge of the output dataset.