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: 
Not applicable

Setanalysis(how to retrieve data from between two values)

Hi,

I have sales table

sales year country:

now i want  sales sum of from  year 1985 to 2010 ,how to write this expression setanalysis.

Thanks,

Cahganti

4 Replies
mahesh_agrawal
Creator
Creator

Hii,

Try the following expression

sum({$<Year={'>=1985<=2010'}>}Sale)

er_mohit
Master II
Master II

try this

Sum({<year = {">=1985<=2012"}>}sales)

or try this

sum( {<year = P({1<year={'>=1985<=2012'}>})>} sales)

Not applicable
Author

this works:

sum({<year = {'>=1985<=2010'}>}sales)

see attached.

Not applicable
Author

Do you need a set analysis ? These are used when we want to retrieve data that are out of scope of the selection.

sum(Sales)

choose the 15 years

that's it

if the years are in the chart, sum(total Sales) to get the total of sales (most of the time used in %)

Fabrice