Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I have a complex model, and a portion of which is displayed below. I'm trying to create a measure that counts the number of 'Base IDs' and that can be filtered by specific columns within the attributes table (via filter/slicer). However, a 'Locale' slicer based upon Locale.Locale should not affect the value should it be changed.
I have created the following measure, but unfortunately the value changes if the Locale.Locale slicer is changed:
# Base ID =
CALCULATE ( COUNT ( Base[Base ID] ), RELATEDTABLE ( Attributes ) )
I have also tried the following measure, but then any slicer/filter applied to 'Attributes' does not work:
# Base ID =
CALCULATE (
COUNT ( Base[Base ID] ),
ALL ( Locale ),
RELATEDTABLE ( Attributes )
)
What am I missing?
Many thanks in advance
Solved! Go to Solution.
I believe the piece you are missing is that you need to modify the filters on the Attributes table, not the Base table. You can do this with CALCULATETABLE. E.g., I think something like this will achieve what you want:
Count_IgnoreLocal =
CALCULATE(
COUNTROWS( Base ),
CALCULATETABLE(
Attributes,
REMOVEFILTERS( Locale )
)
)
I believe the piece you are missing is that you need to modify the filters on the Attributes table, not the Base table. You can do this with CALCULATETABLE. E.g., I think something like this will achieve what you want:
Count_IgnoreLocal =
CALCULATE(
COUNTROWS( Base ),
CALCULATETABLE(
Attributes,
REMOVEFILTERS( Locale )
)
)
Thanks MarkLaf.
Works a treat.
You can try something like this:
# Base ID =
CALCULATE ( COUNT ( Base[Base ID] ), CROSSFILTER(Attributes[Identifier Locale Key], Locale[Key]), None )
Thanks JoBi,
I have tried something similar before, but it doesnt work when applying a slicer etc from the Attributes table.
I am also concerned about the performance as there are more than a millions records in the Attributes table.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.