Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
So i have calculated the seniority for every employee dynamiclly where "Seniority nb = Current Date - First Date of Work" , then i used another measure to show the seniority description : seniority level =if Seniority nb between 1 and 3 => Junior // if between 3 and 5 Advanced and so on.
Is there a way i can filter the total number of employee using the measure "seniority level" ??
Thank you in advance.
Solved! Go to Solution.
It depends on what you're trying to show. As long as the employee is part of the visual then it should work, but I think they would be necessary to provide the context for the measure calculation.
If you were looking to provide totals of the different seniority levels then I think you would need a different measure
It would only be calculated during data refresh, so you would need to schedule at least a daily refresh of the data
Yes that's true but it doesnt help to show the average of seniority for previous years
The only way I can think of to do it with measures is to create a disconnected table containing all the possible text values that could be returned by the measure, use that table as a slicer and create a second measure which returns 1 if the current value of the measure matches SELECTEDVALUE of the table. Not the most efficient but it should work.
I used this tutorial and it works perfectly but is it possible to use this in a visual and not a table ?
https://youtu.be/AHiCE1N0XHE
It depends on what you're trying to show. As long as the employee is part of the visual then it should work, but I think they would be necessary to provide the context for the measure calculation.
If you were looking to provide totals of the different seniority levels then I think you would need a different measure
I don't think you can use a measure which returns a text value as a filter, I think you can only use numeric measures as filters.
However, given that the seniority of employees seems unlikely to be affected by slicers or filters, you could add them both as calculated columns instead of measures and then you would be able to filter on them.
the problem is that the calculated column is not changing when i change the date