The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello,
How can i adapt this measure so that it isnt affect by any of the slicers on this page? I don't want to edit the visual, but the measure itself.
Solved! Go to Solution.
Hello, than you - i only wanted to avoid one slicer actually in the end - i think iv got there with this:
2) AUDIT ITEMS DISTINCT COUNT NO RESULT FILTER) = CALCULATE([1) AUDIT ITEMS ID DISTINCT)],REMOVEFILTERS('Dynamics - Pbi HSE_Audit_Inspections_LC'[Audit Item Result]))
Hello @LYeo87
Not sure if i get your request 100%.
Usually to make your DISTINCTCOUNT measure ignore all slicers/filters on the page, modify it using REMOVEFILTERS (or ALL) to clear any external filter context.
For example if you'd like to ignore all filters, use
Measure =
CALCULATE(
DISTINCTCOUNT('Dynamics - Pbi HSE_Audit_Inspections_LC'[Audit Item ID]),
REMOVEFILTERS()
)
Or specific table/column use
Measure =
CALCULATE(
DISTINCTCOUNT('Dynamics - Pbi HSE_Audit_Inspections_LC'[Audit Item ID]),
REMOVEFILTERS(
'table1', // Ignore filters on table1
)
)
You may also need to use KEEPFILTER('Table'[Column]) with REMOVEFILTER() to reapply Filter of this 'Column'.
Also in some cases, the simplest way to prevent a visual from being filtered by slicers would be to edit the visual interactions under 'Format', but it depends on how your Measure is used in Visual.
Hope this helps:)
Thank you for your help
You can use REMOVEFILTERS to remove all the filters from a calculation
Count =
CALCULATE (
DISTINCTCOUNT ( 'Dynamics - Pbi HSE_Audit_Inspections_LC'[Audit Item ID] ),
REMOVEFILTERS ()
)
Thank you for your help
Hello, than you - i only wanted to avoid one slicer actually in the end - i think iv got there with this:
2) AUDIT ITEMS DISTINCT COUNT NO RESULT FILTER) = CALCULATE([1) AUDIT ITEMS ID DISTINCT)],REMOVEFILTERS('Dynamics - Pbi HSE_Audit_Inspections_LC'[Audit Item Result]))