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
karinafreitass
Helper III
Helper III

Filter Table

Hi guys,

Could someone help me, please?

I would like to filter the following table:

Screenshot (101).png

I am using the following formula to return values ​​that are different from '-9' or bigger then "0", but there is an error.

Cod. Lançamento =
VAR Codigo = CALCULATE(
VALUES('Lançamento'[Não Identificado]),
FILTER('Lançamento',
'Lançamento'[Não Identificado] >= 0)
)
Return
Codigo

 

Which formula could I use?

 

Thanks,

 

Karina

 

 

 

1 ACCEPTED SOLUTION

Hello

Why not apply a simple criterion in the <>-9 filter panel.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

8 REPLIES 8
stevedep
Memorable Member
Memorable Member

Hi,

You could use this check measure:

 

___check = if ( COUNTROWS(FILTER('Table','Table'[id]<>-9 || 'Table'[id] >0))>0,1, BLANK())

 

as seen here:

check.pngLink to file

Please mark as solution if so. Thumbs up for the effort are appreciated.

Kind regards, 
Steve. 

@stevedep I want to return the values, in the case of this example the number 4, 6, 7 and 8. All that contain -9 will not be presented in a visualization table for example

It's filtering the rows in the table, therefore you get the values you are looking for?

@stevedep ,

I still couldn't get it.

Below is the result I would like:

Screenshot (102).png

Hello

Why not apply a simple criterion in the <>-9 filter panel.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
lbendlin
Super User
Super User

VALUES() returns a table.  You can't use CALCULATE with that  - you would need to use CALCULATETABLE().

 

Both of these cannot be the final result of your measure - you need a single ("scalar") value.

 

What should the result of the measure be? A yes/no value?

@lbendlin I want to return the values, in the case of this example the number 4, 6, 7 and 8. All that contain -9 will not be presented in a visualization table for example.

Ah, I misread, it should be <> -9 

In the measure definition that I shared. You should be good then since it will return the rows that meet the filter criteria. Pls take a look.

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! Prices go up Feb. 11th.

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.