How To Use System Variable ‘FirstMonthOfYear‘ In Qlik SenseArticle Number: 000041166 | Last Modified: 2019/03/18
The system variable ‘FirstMonthOfYear ‘ defines which month to use as first month of the year, which can be used to define financial (fiscal) years that use a monthly offset.
Even by modifying the ‘FirstMonthOfYear ‘ value in default script, the value will not be used in function YearStart(date[, period_no[, first_month_of_year]])
For example starting July 1. Set FirstMonthOfYear=7 in script,
yearstart ('19/07/2017') will return ‘01/01/2017’
The expected result would be ‘01/07/2017’
Qlik Sense Nov 2018
Qlik Sense Feb 2019
The variable ‘FirstMonthOfYear‘ is currently unused but reserved for future use as mentioned in Qlik Help Number Interpretation variables (Feb 2019).
The variable FirstMonthOfYear can be a useful environment variable and it can be passed in to any function which has an argument related to the first month of the year.
For example, with FirstMonthOfYear=7:
yearstart ('19/10/2001', 0, $(FirstMonthOfYear)) would return the 1st of July, 2001
For more information about year start please review the product documentation for the Year Start function (Feb 2019).
Have a Question?
Search Qlik's Support Knowledge database or request assisted support for highly complex issues.Submit a case
Experiencing a serious issue, please contact us by phone. View phone numbers and hours by region.