Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
wonkymeister
Creator III
Creator III

MASTER CALENDER

Hi all,

i need to generate a 6 character fiscal year to my master calender script (and i'm struggling)

Our fiscal year starts in August - month 8

and the fiscal YEAR label that i'd like to display - 2018/9

so where the current fiscal year short is 2018 and the month is March i need something like

if(Month(MyDate) => 8 and AddYears(Month(MyDate)+1) <8, MyDate & '/' & Right(MyDate,1)+1

to achieve 2018/9 for the current month as the fiscal year

make sense? Any ideas anyone?

thanks in advance

Labels (1)
1 Solution

Accepted Solutions
dplr-rn
Partner - Master III
Partner - Master III

Try this

if(Month(OrderDate)>=8
,Year(OrderDate)&'/'&(Num(Right(Year(OrderDate),1))+1)
,Year(AddYears(OrderDate,-1))&'/'&Right(Year(OrderDate),1)) as FiscalYear

View solution in original post

2 Replies
dplr-rn
Partner - Master III
Partner - Master III

Try this

if(Month(OrderDate)>=8
,Year(OrderDate)&'/'&(Num(Right(Year(OrderDate),1))+1)
,Year(AddYears(OrderDate,-1))&'/'&Right(Year(OrderDate),1)) as FiscalYear

wonkymeister
Creator III
Creator III
Author

works a treat, many thanks!