Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Aarceoh
Contributor
Contributor

Quarter amount and his accumulated

Hi, i have a pivot table and one of the expressions calculates the amount in function of the selected quarter, but now i need create another expression whos calculated the accumulated amount till the selected quarter. From this way i can show the amount for the selected quarter and his accumulated amount in case to select the quarter two, for example.

Any idea to solve this issue?

Thanks a lot.

Labels (2)
1 Solution

Accepted Solutions
rubenmarin

Hi, if you have calendar that relates echa quarter to his year and month you can use something like:

Sum({<Year={$(=Max(Year))}, NumMonth={"<=$(=Max(NunMonth)"}, Quarter=>} Value)

If quearter selected is 'Q2' (months 4 to 6), the max NumMonth will be 6, this expression will sum the values of max year selected, months from 1 to 6, and ignoring selections of Quarter (to ignore the filter of months 4 to 6).

View solution in original post

2 Replies
rubenmarin

Hi, if you have calendar that relates echa quarter to his year and month you can use something like:

Sum({<Year={$(=Max(Year))}, NumMonth={"<=$(=Max(NunMonth)"}, Quarter=>} Value)

If quearter selected is 'Q2' (months 4 to 6), the max NumMonth will be 6, this expression will sum the values of max year selected, months from 1 to 6, and ignoring selections of Quarter (to ignore the filter of months 4 to 6).

Aarceoh
Contributor
Contributor
Author

Thank you, this works...¡¡¡