cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
adavid999
Helper V
Helper V

show measure result unaffected by slicers

Hello,

I have the following measure and wanted to know what I need to do to replicate the measure and adjust it to show an 'all' figure unaffected by on screen slicer visuals. (this way I can use it to show slicer selections vs an 'all' figure.)

The measure is:

Result = 
VAR denominator =
    CALCULATE (
        SUM (Table1[sub] ),
       Table1[pop] = 1
    )
VAR numerator =
    CALCULATE (
        SUM(Table1[num] ),
        Table1[empnum]<> 0
            && Table1[pop] = 1
    )
RETURN
    numerator/denominator

 Any advice welcome.

Thanks

1 ACCEPTED SOLUTION
rbriga
Impactful Individual
Impactful Individual

You may create a second metric:

Result (All)=
CALCULATE(
[Result],
REMOVEFILTERS(X)
)

 

Where X is a list of on-screen slicers you have in place, for example:

REMOVEFILTERS(Customers[Country],Items[Category])

You can leave it as REMOVEFILTERS(), but it may be an overkill depending on the context, so you better specify the sliced fields.

-------------------------
Data analyst by day, hockey goalie by night.
Did I help? Then please hit that "kudos" or "accept as a solution" button!

View solution in original post

1 REPLY 1
rbriga
Impactful Individual
Impactful Individual

You may create a second metric:

Result (All)=
CALCULATE(
[Result],
REMOVEFILTERS(X)
)

 

Where X is a list of on-screen slicers you have in place, for example:

REMOVEFILTERS(Customers[Country],Items[Category])

You can leave it as REMOVEFILTERS(), but it may be an overkill depending on the context, so you better specify the sliced fields.

-------------------------
Data analyst by day, hockey goalie by night.
Did I help? Then please hit that "kudos" or "accept as a solution" button!

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors