Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
zwyne
Creator
Creator

Set Analysis Expresion Question

Hi Experts,

I have a question to ask you.

 

I’m trying to get percentages on a table so the issue I have is that the calculation must be for a period of 6 months. I have created the variable as vPrevMonth=date(Monthend(date(addmonths(max(APP_MONTH),-5), 'MMM-YY')), 'MMM-YY')  to get the 6 months period but I can’t get it right on the pivot table. The pivot is the calculation done for 1 month, I need the same calculation for a 6 month period.

PFA,

Regards

1 Solution

Accepted Solutions
Anonymous
Not applicable

try this Expression (Need to check the origin values to see if percentage is correct)

=sum({<APP_MONTH={'>=$(=vPrevMonth7)<=$(=max(APP_MONTH))'}>}Count)/sum(total<BA10> {<APP_MONTH={'>=$(=vPrevMonth7)<=$(=max(APP_MONTH))'}>} Count)

View solution in original post

2 Replies
Anonymous
Not applicable

try this Expression (Need to check the origin values to see if percentage is correct)

=sum({<APP_MONTH={'>=$(=vPrevMonth7)<=$(=max(APP_MONTH))'}>}Count)/sum(total<BA10> {<APP_MONTH={'>=$(=vPrevMonth7)<=$(=max(APP_MONTH))'}>} Count)

zwyne
Creator
Creator
Author

Thank you