Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How I can obtain Last headcount data?

Hi,

I have headcount data with monthly periodicity, and I need to obtain the Last version of headcount for every month, i.e. the headcount of this month and not the sum of all months charged.

Any clue how to do that?

Thanks in advance

Nancy

1 Solution

Accepted Solutions
Not applicable
Author

Finally, I created a new column in my source excel file named "Period" like 201301, 201302,...201405 (numeric) and apply the following formula:


sum({$<Period={$(=Max(Period))}>}Headcount)


And it works!

View solution in original post

3 Replies
swuehl
MVP
MVP

Not sure if I've understood your request properly.

If you have access to historic data for your headcount, e.g. headcounts for  each department for each month in the last two years, you can probably limit your data to the most current one by selecting a value in a field that specified e.g. the month the data was created. For example, if you have a field ReportMonth that holds that information, just select 2014-June and a chart with dimension Department and expression =sum(HeadCount) should show the latest information.

if you want to limit the data without selecting, you can use set analysis:

=sum({<ReportMonth = {'2014-June'}>} HeadCount)

Maybe your setting is different or you are asking for something completely different, in both cases, please post more details (best by attaching a small sample application or sample input data) to enable us to help you.

Not applicable
Author

Hi,

I have exactly the formula that you have said: I have in the charge script, a HC of process month, so always I show the HC for the process month (i.e. May) despite I am accumulating expenses from Jan to May.

But now, I need to allow to the users ask for HC of any month. Here I have the problem!

Not applicable
Author

Finally, I created a new column in my source excel file named "Period" like 201301, 201302,...201405 (numeric) and apply the following formula:


sum({$<Period={$(=Max(Period))}>}Headcount)


And it works!