Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How can read last 8 months data

I Want to display a last 8 months data in the expression using SET analysis.


1 Solution

Accepted Solutions
its_anandrjs

Write like

=Sum({$<MonthYear = {">$(=num(AddMonths(today(),-9))) <=$(=Num(addmonths(today(),-1)))"}>} YourSalesValue)

View solution in original post

5 Replies
its_anandrjs

Write like

=Sum({$<MonthYear = {">$(=num(AddMonths(today(),-9))) <=$(=Num(addmonths(today(),-1)))"}>} YourSalesValue)

Not applicable
Author

Can i used it for any Dimension like months and monthname.

its_anandrjs

Yes you can use it for any expression or dimension.

Not applicable
Author

I want to use variable in place of the formula in expression.

its_anandrjs

Create two variables like

vStart  =num(AddMonths(today(),-9))

vEnd =Num(addmonths(today(),-1))

And then use script like

=Sum({$<MonthYear = {">$(vStart) <=$(vEnd)"}>} Sales)