Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
BeginnerBI
Helper I
Helper I

not filtering the table with the year filter

I have all the results wonderful when I do not filter but as soon as I filter per year (like in the red header table ) something happens. Please advise

Capture.PNG

3 REPLIES 3
BeginnerBI
Helper I
Helper I

this is the DAX that I am using 

Completed% =
DIVIDE(
CALCULATE(
COUNTROWS(FILTER('Customer Contact List', NOT(ISBLANK('Customer Contact List'[DateTime])))),
ALL('Customer Contact List'[DateTime].[Year])
),
CALCULATE(
COUNTROWS('Customer Contact List'),
ALL('Customer Contact List'[DateTime].[Year])
)
)

v-zhengdxu-msft
Community Support
Community Support

Hi @BeginnerBI 

 

I've got a general idea of your problem, after you filtered the year with a filter, the Cars and Sold columns got equal.

 

Based on the rendering you want, the Car column should be a sum of values, but it is affected by a filter that only shows the values for the current year.

Use the all(), allselected(), allexcept(), and removefilter() functions to remove unwanted filtering effects.

Here's a blog about contextual filtering, which you can start with the highlights

Understand the Filter Context and How to Control it 

 

Best Regards,

Zhengdong Xu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Jihwan_Kim
Super User
Super User

Hi,

I am not sure how your semantic model looks like, or how your DAX measures look like, but I guess ALL DAX function is used in the DAX measures.

 

In this case or in this scenario, please try using ALLSELECTED DAX function in the measures.

 

ALLSELECTED function (DAX) - DAX | Microsoft Learn

 

 

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Visit my LinkedIn page by clicking here.


Schedule a meeting with me to discuss further by clicking here.

Helpful resources

Announcements
Sept PBI Carousel

Power BI Monthly Update - September 2024

Check out the September 2024 Power BI update to learn about new features.

September Hackathon Carousel

Microsoft Fabric & AI Learning Hackathon

Learn from experts, get hands-on experience, and win awesome prizes.

Sept NL Carousel

Fabric Community Update - September 2024

Find out what's new and trending in the Fabric Community.