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.
Solved! Go to Solution.
Hi,
I am not sure how your datamodel looks like, but please try disconnect the relationship between date table and fact table. And then try the below measure.
Distinct count of active employees =
VAR _active =
SUMMARIZE (
FILTER (
FactEmployement,
(
'FactEmployement'[Ansatt fra] <= MAX ( 'DimDates'[Dates] )
&& OR (
( FactEmployement[Ansatt til] >= MIN ( 'DimDates'[Dates] ) ),
ISBLANK ( FactEmployement[Ansatt til] )
)
)
),
FactEmployement[Ansattnr]
)
VAR result =
COUNTROWS ( _active )
RETURN
result
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
Hi,
Share some data and show the expected result.
Hi,
I am not sure how your datamodel looks like, but please try disconnect the relationship between date table and fact table. And then try the below measure.
Distinct count of active employees =
VAR _active =
SUMMARIZE (
FILTER (
FactEmployement,
(
'FactEmployement'[Ansatt fra] <= MAX ( 'DimDates'[Dates] )
&& OR (
( FactEmployement[Ansatt til] >= MIN ( 'DimDates'[Dates] ) ),
ISBLANK ( FactEmployement[Ansatt til] )
)
)
),
FactEmployement[Ansattnr]
)
VAR result =
COUNTROWS ( _active )
RETURN
result
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
Thank you so much! This is exactly what I was looking for!
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
98 | |
79 | |
64 | |
57 |
User | Count |
---|---|
143 | |
109 | |
89 | |
84 | |
66 |