Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hello, I have managed to create a monthly Database that contains employee ID
I want a measure that check if this employee ID is available in the pervious month, If its not available then the Employee is New.
Same thing goes to Leavers, I want it to check the next month to check if the employee left or not
Solved! Go to Solution.
@Anonymous , I think you need very similar what I disucssed here
Customer Retention Part 1:
https://community.powerbi.com/t5/Community-Blog/Customer-Retention-Part-1-Month-on-Month-Retention/ba-p/1361529
Hi @Anonymous ,
Not sure what your data table looks like, I created a table like this for testing.
Then please create a measure.
Measure =
VAR _pervious_month = MONTH(TODAY())-1
VAR _current_month = MONTH(TODAY())
VAR _employee_1 = CALCULATE(SUM('Table'[ID]),FILTER('Table','Table'[Month]=_pervious_month))
VAR _employee_2 = CALCULATE(SUM('Table'[ID]),FILTER('Table','Table'[Month]=_current_month))
RETURN
SWITCH(
TRUE(),
_employee_1=_employee_2&&_employee_1<>BLANK(),"in-service",
_employee_1<_employee_2,"New",
_employee_1>_employee_2,"Leavers"
)
If this doesn't work for you or I misunderstand your needs, please consider sharing more details about it. And it would be great if there was a sample file without any sensitive information here.
Best Regards,
Community Support Team_Gao
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data
@Anonymous , I think you need very similar what I disucssed here
Customer Retention Part 1:
https://community.powerbi.com/t5/Community-Blog/Customer-Retention-Part-1-Month-on-Month-Retention/ba-p/1361529
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
84 | |
76 | |
73 | |
42 | |
36 |
User | Count |
---|---|
109 | |
56 | |
52 | |
48 | |
42 |