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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

filter on less and equal to values

Hi,

 

In a source table I have a field that contains a number between 1 and 50.

In a page I want to show its records using a table vizualisation.

I want to use a slicer with the values 5, 10, 15, 20, 25, ..., 50

If I select e.g. the value 20 in the slicer, then in the table I get all records with the number 1 to 20

If I select e.g. the value 35 in the slicer, then in the table I get all records with the number 1 to 35

etc.

 

I tried to add a new column =(TRUNC((number-1)/5)+1)*5, but selecting 20 in the slicer, then in the table I get only the records with number 16 to 20, selecting 35 in the slicer, then in the table I get only the records with number 31 to 35

 

I tried to use a new table where I typed in the values 5, 10, 15, 20, ... , 50 and use this for the slicer. And I added a filter where number should be less or equal the selected value in the slicer. The filter doesn't work: all records are shown.

 

How can I solve this problem?

 

Thanks

 

R.W.

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

Hi @Anonymous,

 

Based on my test, we can create a measure as below and filter the measure in the table visual. Then we can get the result as we excepted.

 

Measure = IF(MAX(Source[column])<=SELECTEDVALUE(Table1[Number]),1,0)

Capture.PNG

 

For more details, please check the pbix as attached.

 

https://www.dropbox.com/s/xhutcz72c86tjiq/filter%20on%20less%20and%20equal%20to%20values.pbix?dl=0

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

View solution in original post

2 REPLIES 2
v-frfei-msft
Community Support
Community Support

Hi @Anonymous,

 

Based on my test, we can create a measure as below and filter the measure in the table visual. Then we can get the result as we excepted.

 

Measure = IF(MAX(Source[column])<=SELECTEDVALUE(Table1[Number]),1,0)

Capture.PNG

 

For more details, please check the pbix as attached.

 

https://www.dropbox.com/s/xhutcz72c86tjiq/filter%20on%20less%20and%20equal%20to%20values.pbix?dl=0

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Hi, I have a similar problem. I am actually not following what is the Table1[Number] so wanted to check the file. Can you please reattach the pbix file? It is throwing a 404 error when I tried to use the dropbox link you provided.
Hoping for a reply from you 🙂

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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