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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Multiple Column, multiple IFS and multiple Returns

Hello All,

I'm am trying to return a text based off of IFS in two columns.  I'm not sure how I go about it.  The "Score Rank" column was fairly easy to do, but I'm not sure about adding another column to the equasion. 

 

Thank you.  

michaelhaga_0-1674481463711.png

 

 

 

1 ACCEPTED SOLUTION

hi @Anonymous 

this info is critical, try this:

Score_Rank = 
SWITCH(
    TRUE(),
    [Type]="Issue", [Type],
    [Probability]<8, "low",
    [Probability]<15, "medium",
   "high"
)

 

FreemanZ_0-1674488545791.png

View solution in original post

5 REPLIES 5
Anonymous
Not applicable

Thank you for the quick response, but I'm not sure if I'm understanding. 

This is how I created the Score Rank column:

 

Score_Rank = IF(AND([Risk score]>=0, [Risk score]<8),"low",
 IF(AND([Risk score]>=8, [Risk score]<15),"medium",
  IF(AND([Risk score]>=15, [Risk score]<30),"high")))
 
The "score_rank" column I'm trying to populate has to have that, but if "issue" is in the Type column, then I need to return "Issue" instead of low, medium, or high.  
 
Thank again,
Mike
 

hi @Anonymous 

this info is critical, try this:

Score_Rank = 
SWITCH(
    TRUE(),
    [Type]="Issue", [Type],
    [Probability]<8, "low",
    [Probability]<15, "medium",
   "high"
)

 

FreemanZ_0-1674488545791.png

Anonymous
Not applicable

Thank you.  That's got me about 90% there. 

I should have been more specific with calculation explanation.  If the type is "Issue", then the only value it can return is "Issue"  For "Risk", it follows the below criteria:

Low = 0-8

Med = 9-14

High = 14+

 

RS

Mike

The formula is returning incorrect values for the Score_Rank column. 

Example of what's its returning:

 

Type     Prob  Score Rank  Score_Rank

Risk      9         Medium      Low

Risk       5

FreemanZ
Super User
Super User

hi @Anonymous 

try like:

Column =
IF(
[Type]="Issue",
[Type],
[Score Rank]
)

amitchandak
Super User
Super User

@Anonymous , What is logic use

 

One is

 

Switch( True() ,

[Rank] <= 5, "Low",

[Rank] <= 10, "Med",

"High"

)

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.