cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
JoyceW
Helper I
Helper I

Measure with a filter all and a page filter

Hi,

 

I have the following measure:

 

Voorraadwaarde =
CALCULATE (
    SUM ( Grootboekmutaties[Bedrag] ),
    FILTER (
        ALL ( GrootboekRekening[GrootboekCategorieCodeNiveau2] ),
        GrootboekRekening[GrootboekCategorieCodeNiveau2] = " 05"
    )
)

 

I have a page with a filter on Debiteurcode is not 998. 

 

I want that page filter not to be applied to the above measure. I have tried with ALL(debiteurcode) and ALLEXCEPT, but I can't get it to work. Any help is very much appreciated. Thank you!

1 ACCEPTED SOLUTION

I figured it out!

 

Voorraadwaarde =
CALCULATE (
SUM ( Grootboekmutaties[Bedrag] ), REMOVEFILTERS(Debiteur[DebiteurCode]),
filter(GrootboekCategorieNiveau2, GrootboekCategorieNiveau2[GrootboekCategorieOmschrijvingNiveau2] = "Voorraden"))

View solution in original post

6 REPLIES 6
tamerj1
Super User
Super User

Hi @JoyceW 

the Debiteurcode from which table?

Sorry, it is Debiteur[DebiteurCode] 

@JoyceW 

You can try to CROSSFILTER the relationship with Debiteur table to NONE

Hi, that didn't work unfortunately. 

@JoyceW 
Yes it won't. Actually the tablr supplied to the visual is prefiltered by the page filter even crossfiltering the relation to non won't restore the rows filtered out by the page filter. I don't know of any method that can do that but I hope others will.

I figured it out!

 

Voorraadwaarde =
CALCULATE (
SUM ( Grootboekmutaties[Bedrag] ), REMOVEFILTERS(Debiteur[DebiteurCode]),
filter(GrootboekCategorieNiveau2, GrootboekCategorieNiveau2[GrootboekCategorieOmschrijvingNiveau2] = "Voorraden"))

Helpful resources

Announcements
Carousel_PBI_Wave1

2023 Release Wave 1 Plans

Power BI release plans for 2023 release wave 1 describes all new features releasing from April 2023 through September 2023.

Power BI Summit Carousel 2

Global Power BI Training

Make sure you register today for the Power BI Summit 2023. Don't miss all of the great sessions and speakers!

BizApps LATAM 2023

Business Application LATAM Summit 2023

Join the biggest FREE Business Applications Event in LATAM this February.

Power Platform Bootcamp

Global Power Platform Bootcamp

In this bootcamp we will deep-dive into Microsoft’s Power Platform stack with hands-on sessions and labs, delivered to you by experts and community leaders.

Top Solution Authors
Top Kudoed Authors