1 Reply Latest reply: Feb 19, 2015 4:45 PM by Chris Deniziak RSS

    Set Analysis based on min/ max slider variables

      Dear Qlikview experts,

       

      I have a pivot table with 2 dimensions: client name & employee and 3 expressions: planned hours, performed hours, bugetted hours.

       

      These 3 hours come from 3 source files, with the client name being the key that occurs in every file (in my load script, client name is a common field).

       

      The goal is to show a table that per client shows the actual hours performed, planned hours to come and then the budgetted hours.

       

      I created a multi value slider, which holds the dates of the performed hours. When i change this slider, the performed hours in the table change (which is OK). 

       

      Next step, the goal was to make the planned hours be calculated as all the hours planned, starting from the last date selected in the slider. I figured out that i can make the slider based off on variables being min() and max() of the performed hours. I thought i could grab the max() variable and make a set analysis in my table based off on the values for these variables.

       

      Any set expression that i try however, is not working.  Additionally, now that the slider is based on variables, the performed hours also don't update anymore, so i assume a set expression is needed here aswell?

       

      Example set expression: =Sum({< Date_Actuals = {">=$(=Date(vBegin, 'DD/MM/YYYY')<=$(=Date(vEnd, 'DD/MM/YYYY')"} >} [Perf. Hours])

       

      where vBegin and vEnd are my slider min and max dates. I echoed them in a text box and they work.

       

      Can somebody point me in the right direction?

       

      Thanks in advance,