Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Lisa_G
Frequent Visitor

Count Data in the course of time

Hi,

every employee in our company has to make 50 suggestions for improvement (CIP) per year respectively one per week. Our goal is to make a  line chart where we can see the cumulated goal and the total cumulated CIP`s per FTE or per Unit (e.g. Department Accounting). We want to consider new hires and/or employees that are leaving.

 Based on the table below we have drawn the cart in Excel:

 Target Chart.png

 

We have this data: name of employee, departement of employee, entry and leaving date, every CIP with the submission date(we can count) and the target of 50 CIP´s per year/FTE.

  

Example data:

 Unbenannt.PNG

 

Best regards,

Lisa

2 REPLIES 2
v-caliao-msft
Employee
Employee

@Lisa_G,

 

I have tested it on my local environment, the steps below are for you reference.

  1. Create a Weeknumber table.
    Table = SUMMARIZE(CIP,CIP[CSubmissionWeek],"WeekTotal",CALCULATE(SUM(CIP[CIP]),ALLEXCEPT(CIP,CIP[CSubmissionWeek])))
  2. Create a calculated column by using the DAX expression below.
    EmployeeCount = CALCULATE(COUNT(Employee[EmployeeID]),FILTER(Employee,Employee[EntryWeek]<='Table'[CSubmissionWeek]&&Employee[LeavingWeek]>='Table'[CSubmissionWeek]))
  3. Create two running total measure.
    RunningtotalSuggestions = CALCULATE(SUM('Table'[WeekTotal]),FILTER(ALL('Table'),'Table'[CSubmissionWeek]<=MAX('Table'[CSubmissionWeek])))
    RunningtotalOneEmployeeOneSuggestionPerWeek = CALCULATE(SUM('Table'[EmployeeCount]),FILTER(ALL('Table'),'Table'[CSubmissionWeek]<=MAX('Table'[CSubmissionWeek])))

Sample table
Capture.PNGCapture1.PNG

Results
Captur2e.PNG

 

Regards,

Charlie Liao

Hi Charlie Liao,

thank´s for your help!

The column EmployeeCount don´t give me the right figure. Maybe because I have entry dates and leaving dates over years and not only for 2017? -> We have to combine week and year of the dates.

The result is a fixed chart. I can´t use e.g. a basic filtering by the employee because the measures have no connection to this informations. E.g. I want to drill down the chart to see how many CIP´s employee 1001 made in week 1.

 

Do you know a way to solve this?

 

Regards,

Lisa

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.