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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

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])
)
)

Anonymous
Not applicable

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.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.