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

Announcements
Congratulations to the new Qlik Luminary and Partner Ambassador class! Meet them here
cancel
Showing results for 
Search instead for 
Did you mean: 
Jo_Makin_Dev
Contributor
Contributor

Block a filter from working

Hi,

I am using the below formula to work out volume of sales to date up until the maximum date selected. If a user selects 2021 it counts all the sales to date up to and including 31/12/2021. I had to use the 1 modifier to make it calculate all sales and not just those in 2021. The problem is that if a user selects something in the "Reason" filter it affects the calculation when I need it not to. 

Can anyone help please?

Count({1<Reason=,Fact_Type={'P'},DateType={'Sales'},Type={'Red'},Status={'Active'},[Sales date]={"<=$(=Date(Max(Date),'DD/MM/YYYY'))"}>}[Item])

Labels (2)
1 Solution

Accepted Solutions
kaushiknsolanki
MVP
MVP

It does change because of your Max Function.

You will have to neglect the selection in Max function also. So your expression will look like below.

Count({1<Reason=,Fact_Type={'P'},DateType={'Sales'},Type={'Red'},Status={'Active'},[Sales date]={"<=$(=Date(Max({<Reason=>}Date),'DD/MM/YYYY'))"}>}[Item])

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!

View solution in original post

2 Replies
kaushiknsolanki
MVP
MVP

It does change because of your Max Function.

You will have to neglect the selection in Max function also. So your expression will look like below.

Count({1<Reason=,Fact_Type={'P'},DateType={'Sales'},Type={'Red'},Status={'Active'},[Sales date]={"<=$(=Date(Max({<Reason=>}Date),'DD/MM/YYYY'))"}>}[Item])

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
Jo_Makin_Dev
Contributor
Contributor
Author

Thank you so much for this 🙂