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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

help in set analysis

Hi All,

i am calculating  values for YearToGo in set expression.

My requirement is i have calculated MTD,YTD

I am struck wih calculating YearToGo.

I want the sum of values which are not included in the selection.

let suppose I have  months jan to dec .IF i select jan i have value YTD,MTD .

IF i select jan  i need to calculate YearToGo which is sum of Feb to Dec .

Any ideas are appreciated

4 Replies
Not applicable
Author

Hi RGV,

try to use

sum({<date={'>= $(SelectedDate) <= $(YearToGo)'}>}Value)

Where date is your date filed,

and SelectedDate is a variable storing the selected day.

and  YearToGo is a variable storing the end of year using YearEnd Function.

be careful to the date format in variables.

hope it is helpful to you.

Not applicable
Author

Use the below expression:

Sum(

          {<DateField={">=$(AddMonths(MonthStart(Max(DateField)),1))<=$(AddMonths(MonthEnd(Max(DateField)),12))"}>}           SaleAmount

       )

Anonymous
Not applicable
Author

Hi,

try:

Sum({$<Date = {">=$(=AddMonths(MonthStart(Max(Date)), 1))<=$(=AddMonths(MonthEnd(Max(Date)), 11))"}>} Sales)

Anonymous
Not applicable
Author

Hi All,

I tried with below expression.

sum({<Month={'>$(vSeletedMonth)'}>}sales)

vSelectedMonth  = max(Month)

Even the above is also working fine .