Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

prasannazad
New Contributor III

Help on set variable

Hi,

I am trying to make a pivot table which comprise of budget headcount data (month on month) . By design, the headcount numbers are progressive (e.g  Feb'17 heacount numbers, will show Jan+Feb (YTD)). i need help on how to ensure that for any given month, the table shows me data relevant only to that period.

my set variable

sum({<Scenario={Budget}, HeadCountType={"HC Request","PH","Open","PHWS","Attrition Replacement"},DateType={THD},year={$},month={$}>}[FTE_Alloc])

Thanks in advance

4 Replies
MVP
MVP

Re: Help on set variable

Are you using Year and Month as your dimensions?

prasannazad
New Contributor III

Re: Help on set variable

Yes i am

antoniotiman
Honored Contributor III

Re: Help on set variable

You remove

Month={$),Year{$} don't need

Correct is

Year=$::Year,Month=$::Month

however You don't need because you don't have any Alternate State in Your Expression.

Default is Current state/selection {$}

MVP
MVP

Re: Help on set variable

In that case you have two options

1) Use The As-Of Table

2) Use Missing Manual - Above() and Below() functions