On weekly basis I am loading new data to my database. In QV I have a simple list box that allows me to choose a reporting week. Say, for example, I have 10 weeks worth of data in my QV app. On Monday I will load week 11 data. How can I make QV automatically select the latest week (week 11) in the week selection list box to report on it?
You could do this using so called triggers and actions in QlikView.
First select a trigger, if you want something be done automatically you could go to document properties, tab triggers and select an "OnOpen" trigger. Or go to sheet properties, tab triggers and select "OnActivateSheet".
Then you need to add an action, action type is "Selection", action "Select in Field".
Set the field to your field name for week, I assume
(as is, no equal sign, just the name in the input field).
Thanks for the answer. In principle this works. However, I missed to provide a crucial piece of info
week and year numbers (i also want to filter on year) reside in 2 tables:
1) calendar master
calendar master carries week numbers (52) for entires years (2010-2015). My sales table holds data for only uploaded weeks. The problem with the =max statement is that i always get week 52 and year 2015 selected.
Is there a workaround to only select max year 2012) and max week (11) from the sales table?