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
MathildaP
Frequent Visitor

Filter not working in Power BI desktop

I am trying to put a filter on a column in Power BI but the filter returns the opposite of what I have filtered. 😕

 

I tried to trim the text but this did not help. 

1 ACCEPTED SOLUTION

The project1,2, 3 are the opposite of what I put in the filter.

= Table.SelectRows(#"Replaced Value5", each ([WorkspaceName] <> "Projectname1" and [WorkspaceName] <> "Projectname2" and [WorkspaceName] <> "Projectname3"))

 

= Table.SelectRows(#"Replaced Value5", each ([WorkspaceName] <> "Projectname1" and [WorkspaceName] <> "Projectname2" and [WorkspaceName] <> "Projectname3"))

Im thinking the error has somehow to do with this but this is a previous step that is needed for something else:
#"Replaced Value5"

View solution in original post

3 REPLIES 3
DaleH
Resolver I
Resolver I

@MathildaP Would you please share the code?  Thx

The project1,2, 3 are the opposite of what I put in the filter.

= Table.SelectRows(#"Replaced Value5", each ([WorkspaceName] <> "Projectname1" and [WorkspaceName] <> "Projectname2" and [WorkspaceName] <> "Projectname3"))

 

= Table.SelectRows(#"Replaced Value5", each ([WorkspaceName] <> "Projectname1" and [WorkspaceName] <> "Projectname2" and [WorkspaceName] <> "Projectname3"))

Im thinking the error has somehow to do with this but this is a previous step that is needed for something else:
#"Replaced Value5"

Hi @MathildaP 

Sorry I'm a little confused. You want to keep rows with "Projectname1", "Projectname2", "Projectname3" or remove rows with these three values?

 

If you want to keep these rows, try

= Table.SelectRows(#"Replaced Value5", each ([WorkspaceName] = "Projectname1" or [WorkspaceName] = "Projectname2" or [WorkspaceName] = "Projectname3"))

041604.jpg

 

If you want to remove these rows, try your original codes.

041603.jpg

 

Regards,
Community Support Team _ Jing
If this post helps, please Accept it as the solution to help other members find it.

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.