Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

asmithbi
Not applicable

Set Analysis - Annual Sum

Hello,

I am trying to sum sales for a year based on the Year list box using the following expression. 

sum({$<Year = {$(=max(Year))}>} (MainAmount)) 

The issue is I am losing the annual sales sum when I select a month from the Month list box.  Other than the Year list box, I don't want any other time dimension to effect summing for the year.

Thank you in advance for any help with this issue.

Tags (1)
1 Solution

Accepted Solutions
chiru_thota
Not applicable

Re: Set Analysis - Annual Sum

You ignore Month and other dimensions from the expression.


sum({$<Month=,Date=,Year = {$(=max(Year))}>} (MainAmount))

5 Replies
chiru_thota
Not applicable

Re: Set Analysis - Annual Sum

You ignore Month and other dimensions from the expression.


sum({$<Month=,Date=,Year = {$(=max(Year))}>} (MainAmount))

er_mohit
Not applicable

Re: Set Analysis - Annual Sum

Try this

sum({<Year = {$(=max(Year))},MonthField=,Datefield=>} MainAmount)

MK_QSL
Not applicable

Re: Set Analysis - Annual Sum

SUM({$<

          Year = {'$(=Max(Year))'},

          Field1YouWantToIngore = ,

          Field2YouWantToIngore = ,

          Field3YouWantToIngore =

          >}Amount)

maxgro
Not applicable

Re: Set Analysis - Annual Sum

asmithbi
Not applicable

Re: Set Analysis - Annual Sum

Thank you all for your help!