Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Fix some field selections

I want to fix Month, Year and Quarter selections as fixed if any selections made until I clear it, and rest I should able to switch in data filters corresponding to it; because now, when I switch in data filters if data is associated with multiple years, it kicks out of Year filter, etc.. How can I make it?

6 Replies
morganaaron
Specialist
Specialist

Have you tried locking the fields? That would stop any values not associated with your values in the Month etc. fields overriding the selections you've mentioned.

jpenuliar
Partner - Specialist III
Partner - Specialist III

Why not have additional Fields - Month & Year, Quarter & Year, Week & Year

This way, you can lock you selection to a specific year when you want specific period within that year.

jpenuliar
Partner - Specialist III
Partner - Specialist III

or do away with Bookmarks.

jpenuliar
Partner - Specialist III
Partner - Specialist III

I agree with Aaron, You can lock the field and unlock when you want to view other years.

Anonymous
Not applicable
Author

I do not understand how I can make it with bookmarks, this is not in activation of sheet ; activation in selection of 3 filter objects.. could you please elaborate!

We can not have a filter of that type with two many options in Month and Year, Quarter in Year (as per user Requirement) for now!!

JonnyPoole
Former Employee
Former Employee

Locking sometimes introduces a confusing experience to the user even if it does exactly what you are asking for. Alternative is SET ANALYSIS on your expressions to fix Year,Month and Quarter selections if any on all or some expressions.

You would use variables for each to capture the range of possibilities in the current selection state as a delimitted list as follows

vYear= concat(distinct Year, chr(39)&','&chr(39))      ->     2009','2010','2011

vMonth= concat(distinct Month, chr(39)&','&chr(39))    ->   Jan','Feb','Mar

vQuarter= concat(distinct Month, chr(39)&','&chr(39))      ->   Q1','Q2','Q3

An expression would look like this :

sum(   {$<Year = {'$(vYear)'},Month={'$(vMonth)'},Quarter={'$(vQuarter)'}>}    Sales)

and resolve to something like this:

sum (  {$Year=  {' 2009','2010','2011'}, Month={'Jan','Feb','Mar'},Quarter={'Q1','Q2','Q3'}>}  Sales)

This way your selections are always applied....