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.
Hi all,
I've calculated a field and I want to filter this field by gender. I've calculated this field as follows:
CALCULATE (
COUNT ( [Pers.no.] ),
FILTER ( ALL ( 'UPDATED' ), 'UPDATED'[Data Tarihi] = MAX ( 'UPDATED'[Data Tarihi] ) )
)
Shortly, I wanted to see head counts of the most recent date. And now I want to filter this calculated field by gender. It should look like "pers.no" field which shows men and women's numbers. But as you see it remains the same. What should I do? thank you.
Hi @brcnyc ,
If you create a measure, you can replace all with allselected.
CALCULATE (
COUNT ( [Pers.no.] ),
FILTER ( ALLSELECTED ( 'UPDATED' ), 'UPDATED'[Data Tarihi] = MAX ( 'UPDATED'[Data Tarihi] ) )
)
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@brcnyc I think this may be what you are looking to do:
CALCULATE (
COUNT ( [Pers.no.] ),
FILTER ( ALLEXCEPT ( 'UPDATED','UPDATED'[Cinsiyet] ), 'UPDATED'[Data Tarihi] = MAX ( 'UPDATED'[Data Tarihi] ) )
)
Using the ALLEXCEPT https://docs.microsoft.com/en-us/dax/allexcept-function-dax.
This should keep the Gender as a filter.
Respectfully,
Zoe Douglas (DataZoe)
Follow me on LinkedIn at https://www.linkedin.com/in/zoedouglas-data
See my reports and blog at https://www.datazoepowerbi.com/
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 |
---|---|
106 | |
98 | |
75 | |
63 | |
62 |
User | Count |
---|---|
135 | |
105 | |
104 | |
80 | |
65 |