Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hi, i am new with power BI and i am wondering how to create a measure using a filter on another measure, but using allexcept. The goal is for example to have all the sports sales except for hockey and basket,
Thank you
Solved! Go to Solution.
Whoops, had my NOT in the wrong spot.
Sales excl 2 = CALCULATE ( SUM ( 'table'[Sales Amount] ), NOT 'table'[Sport] IN {"hockey","basketball"} )
Whoops, had my NOT in the wrong spot.
Sales excl 2 = CALCULATE ( SUM ( 'table'[Sales Amount] ), NOT 'table'[Sport] IN {"hockey","basketball"} )
It works, thanks a lot!
No, that would be this.
Sales 2 = CALCULATE ( SUM ( 'table'[Sales Amount] ), 'table'[Sport] IN {"hockey","basketball"} )
That is not really what ALLEXCEPT is for. To do what you are describing would be along these lines.
Sales excl 2 = CALCULATE ( SUM ( 'table'[Sales Amount] ), 'table'[Sport] NOT IN {"hockey","basketball"} )
When i write, it highlights the word NOT in red saying it's an unexpected expression?
ok, and i guess if i want to create the same type of mesure except this time by filtering the sales for hockey AND basket, i just have to write :
CALCULATE ( SUM ( 'table'[Sales Amount] ), 'table'[Sport] IN {"hockey"}, 'table'[Sport] IN {"basketball"} )
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
142 | |
80 | |
64 | |
52 | |
48 |
User | Count |
---|---|
212 | |
89 | |
79 | |
68 | |
60 |