cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
Anonymous
Not applicable

Sort a TEXT field

Hi ,

 

Hi,

 

I have a DAX as below where if the field is "Red OR Amber" then I show the value else its blank.

Column = IF(Table1[Health] IN {"Red","Amber"} ,Table1[Values],"")
 
The challenge is that if I use this - I cannot sort as the column has to be modeled as Text.
Sorting by Table1[Values] is showing error.
How can I fix this?
 
Need Help!
Thanks
 
1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous 

Use blank()

Column = IF(Table1[Health] IN {"Red","Amber"} ,Table1[Values],blank())

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@Anonymous 

Use blank()

Column = IF(Table1[Health] IN {"Red","Amber"} ,Table1[Values],blank())

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors