Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

set analysis MonthName problem

Hi,

I have a set analysis problem, I want to see the sum of sales of the max month and year and later max monthyear -1. I used these set analysis expressions:

max(MonthYear)  gives 41306 so i used MonthName(max(MonthYear))  which gives me the text: feb 2013

But when I use it to calculatie the sum of the sales I don't get a result:

num(sum({$<MonthYear={$(=MonthName(max(MonthYear)))}>}Sales),'#.##0,00') 

There is no problem in my data because num(sum({$<MonthYear={'feb 2013'}>}Sales),'#.##0,00')  gives me a result.

Does anyone know what's wrong with my syntax?

1 Solution

Accepted Solutions
sbaldwin
Partner - Creator III
Partner - Creator III

Hi, try adding quotes round your $ expansion ie:

num(sum({$<MonthYear={'$(=MonthName(max(MonthYear)))'}>}Sales),'#.##0,00')

Thanks

Steve

View solution in original post

2 Replies
sbaldwin
Partner - Creator III
Partner - Creator III

Hi, try adding quotes round your $ expansion ie:

num(sum({$<MonthYear={'$(=MonthName(max(MonthYear)))'}>}Sales),'#.##0,00')

Thanks

Steve

Not applicable
Author

Yes! Thanks for your help.