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

Announcements
Solving the Informatica Dilemma: On-Demand Briefing - Watch On Demand!
cancel
Showing results for 
Search instead for 
Did you mean: 
mohitd910
Creator II
Creator II

Restricting Filters on a exp.

Dear all,

This is  my Exp. I want to restrict it for all filters which is present in the current sheet.

Count(Distinct {1<Date_Date={"$(=vToday)"}, Flag={'visits day & Type'}>} IH_EMR_PAT_ID )


stalwar1

mrkachhiaimp

mayilvahanan

mto



Regards,

Mohit Dahiya

1 Solution

Accepted Solutions
jagan
Partner - Champion III
Partner - Champion III

Hi Mohit,

Try this, it won't change you variable.

vToday=Date(Max({1}Date_Date),'DD/MM/YYYY')


Regards,

jagan.

View solution in original post

16 Replies
its_anandrjs
Champion III
Champion III

In your expression add {1} to avoid all the filter selection.

Ex:-

Sum ({1}  [Sales amount])

Your Expression

Count({1}  Distinct {1<Date_Date={"$(=vToday)"}, Flag={'visits day & Type'}>} IH_EMR_PAT_ID )

Regards,

Anand

mohitd910
Creator II
Creator II
Author

Not working Bro

its_anandrjs
Champion III
Champion III

Check the attached example file.

In that no filter is affeted on the chart values.

Is this you required.

Regards

Anand

mohitd910
Creator II
Creator II
Author

i dont have server so i cant open this file can you send me the exp. i am using Qlik Sense

jagan
Partner - Champion III
Partner - Champion III

Hi Mohit,

Count({1<Date_Date={"$(=vToday)"}, Flag={'visits day & Type'}>}  Distinct  IH_EMR_PAT_ID )


This should work.  Not sure why it is not working for you.


What is the value in the vToday?  Is it changing based on the selections?  In that case then you have to change that variable.


If you attach a sample file then it would be easier to provide solution.


Regards,

Jagan.

mohitd910
Creator II
Creator II
Author

Yes it is changes when i am selecting year.

vToday=Date(Max(Date_Date),'DD/MM/YYYY')

its_anandrjs
Champion III
Champion III

Expression is same also your expression is working

Count({1}  Distinct {1<Date_Date={"$(=vToday)"}, Flag={'visits day & Type'}>} IH_EMR_PAT_ID )


Regards

Anand

mohitd910
Creator II
Creator II
Author

value for this exp is 1 by default for the Guest

but when i am selecting year 2015 see it will change to 5Capture2.PNGCapture.PNG

jagan
Partner - Champion III
Partner - Champion III

Hi Mohit,

Try this, it won't change you variable.

vToday=Date(Max({1}Date_Date),'DD/MM/YYYY')


Regards,

jagan.