Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

More than and less than in a Filter

Hi,

I have been trying to put together a set analysis in a filter and got it to work on the basic level. i.e.

=[Shirt Orders]<=720  or

=[Shirt Orders]>1000

and the output in the filter drop down is -1 and 0 that is fine.

When I add more than or less than the functionality did not work.

=[Shirt Orders]>1000<=1200

I also tried

Count({<[Shirt Orders] = {">$(1000)<=$(1200)"}>} [Shirt Orders])


but it did not work.

Any help is appreciated.


Kurleigh

15 Replies
sunny_talwar

You would need to use Aggr() function.... May be like this

Aggr(

If(Count({$<[Shirts]={"blue"},[shirt orders]={"<=700"}>}[shirt orders]), 'Blue Shirt orders Less than 700',

If(Count({$<[Shirts]={"red"},[shirt orders]={">200"}>}[shirt orders]), 'Red shirt order above 200', 'All other Shirts')), Shirts)

Not applicable
Author

Aggr(

If(Count({$<[Shirts]={"blue"},[shirt orders]={"<=700"}>}[shirt orders]), 'Blue Shirt orders Less than 700',

If(Count({$<[Shirts]={"blue"},[shirt orders]={">700<=1440"}>}[shirt orders]), 'between 700 and 1440', 'All other Shirts')), Shirts)


Even though I said only count those <=700 it still counted all the shirts in the first bucket and the second and third was not created.


sunny_talwar

How about trying this

Aggr(

If([Shirts] = 'blue' and [shirt orders] <= 700, 'Blue Shirt orders Less than 700',

If([Shirts] = 'blue' and [shirt orders] > 700 and [shirt orders] <= 1440, 'between 700 and 1440', 'All other Shirts')), Shirts)

sunny_talwar

Or just this

If([Shirts] = 'blue' and [shirt orders] <= 700, 'Blue Shirt orders Less than 700',

If([Shirts] = 'blue' and [shirt orders] > 700 and [shirt orders] <= 1440, 'between 700 and 1440', 'All other Shirts'))

Not applicable
Author

Woot Woot.

Thanks man it worked!!

sunny_talwar

Awesome