Solved

PowerPivot - Count the Values that were in a Previous Period but Not in Current Period

Posted on 2014-12-18
3
121 Views
Last Modified: 2014-12-25
I'm working to calculate a Turnover Report. I've got an export of Employee ID's by week and would like to count the number of Employees ID's that did not return from working the previous week.

Basically Count the entries that didn't reoccur.

I've attached a basic version of the file I've started with the data loaded into PowerPivot via a Linked Table along with a Calendar Table.

If you look at the data an example would be that EmployeeID 1158 worked on 11/2/2014, but didn't work on 11/9/2014. I want to be able to count all the various EmployeeID's where this is the case. So the count of Employees that worked in the previous week, but not in the current week. In this example the count would be under Week 11/9/2014.
0
Comment
Question by:thomas-sherrouse
3 Comments
 
LVL 23

Expert Comment

by:Eirman
ID: 40507337
Try again with the attachment.
0
 

Author Comment

by:thomas-sherrouse
ID: 40507349
Sorry File attached
TurnoverExample-PowerPivot.xlsx
0
 
LVL 85

Accepted Solution

by:
Rory Archibald earned 500 total points
ID: 40508988
You could create a new calculated column to show the employee id only for rows where the employee didn't work the following week:
=if(isblank(countrows(filter(EmployeeList,EmployeeList[EmployeeID]=earlier(EmployeeList[EmployeeID])&&EmployeeList[WeekWorked]=earlier(EmployeeList[Next Week])))),EmployeeList[EmployeeID],blank())

then you would need to use your 'Next week' column as the date grouping and count the distinct rows for the new column.
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
As technology users and professionals, we’re always learning. Our universal interest in advancing our knowledge of the trade is unmatched by most industries. It’s a curiosity that makes sense, given the climate of change. Within that, there lies a…
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…
This Micro Tutorial will demonstrate on a Mac how to change the sort order for chart legend values and decrpyt the intimidating chart menu.

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question