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

Don'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.

Reply
jmateu88
Helper I
Helper I

Visual filter for a dax measure

Hello,
I have a doubt about a basic thing that I really feel as important thing to use. I am talking about having a slicer based in a dax measure which allows me to filter some data.

 

jmateu88_0-1721375203338.png

I created a basic example in this picture where we can see a different amount depending the person aggregated by year.
What I would like to be able is to create a slicer about the measure 'Quantity' which is the sum of the column 'Amount'.

We know that the use of 'Amount' as a slicer is not the proper one because, in fact, it is giving the option to filter by the amount by rows.

What I am looking for is a slicer where we can have a range from 222 to 379 or 0 to any amount where we can exclude for example to 'Rose' from the graph if the minimum value in the slicer is above 222.

Thank you in advance!

1 ACCEPTED SOLUTION
v-linhuizh-msft
Community Support
Community Support

Hi @jmateu88 ,

 

@Ritaf1983 , thanks for your concern about this case. I tried to create a sample data myself based on the user's requirement. Please check if there is anything that can be improved. Here is my solution:

 

1.Create a simple data:

 

vlinhuizhmsft_1-1721625093521.png

 

2.Create a calculated column:

 

 

Column = CALCULATE(SUMX('Table','Table'[Quantity]),ALLEXCEPT('Table','Table'[ID]))

 

 

vlinhuizhmsft_2-1721625135145.png

 

3.Use the Column as the field of slicer:

vlinhuizhmsft_3-1721625259709.png

4.The final results are as follows:

vlinhuizhmsft_0-1721625058163.png

Best Regards,
Zhu
Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

View solution in original post

4 REPLIES 4
v-linhuizh-msft
Community Support
Community Support

Hi @jmateu88 ,

 

@Ritaf1983 , thanks for your concern about this case. I tried to create a sample data myself based on the user's requirement. Please check if there is anything that can be improved. Here is my solution:

 

1.Create a simple data:

 

vlinhuizhmsft_1-1721625093521.png

 

2.Create a calculated column:

 

 

Column = CALCULATE(SUMX('Table','Table'[Quantity]),ALLEXCEPT('Table','Table'[ID]))

 

 

vlinhuizhmsft_2-1721625135145.png

 

3.Use the Column as the field of slicer:

vlinhuizhmsft_3-1721625259709.png

4.The final results are as follows:

vlinhuizhmsft_0-1721625058163.png

Best Regards,
Zhu
Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

Hello @v-linhuizh-msft  and thank you for the right answer.
I was expecting something different in order to not make dirty the table but, the code has sense and it is totally correct.

 

Thank you very much!

Ritaf1983
Super User
Super User

Hו @jmateu88 

Can you please share a pbix or some dummy data that keep the raw data structure with expected results? It should help us clarify your scenario and test to coding formula.

How to Get Your Question Answered Quickly  

 

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Hello @Ritaf1983 and thanks for the suggestion.

I will keep it in mind for the next suggestion.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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