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

Multiple if in M query

Hi All,

image.png

 

 

I should create a new Custom Column in powerquery window(M query).

if practice = "Technology" and Product = "Agility Loyalty" should print as "Agility Loyalty"

if practice = "Technology" and product = "FRMS" should print as "FRMS"

if practicre = "Technology" and Product = "Harmony Platform" should print as "Harmony Platform" 

rest all the all should print as Practice column.

I need all in 1 colum like highlited in Yellow in the above.

 

Thanks in Advance!!

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , new column in M like

if [Practice] = "Technology" and [Product] = "Agility Loyalty" then "Agility Loyalty" else
if [Practice] = "Technology" and [Product] = "FRMS" then "FRMS" else
if [Practice] = "Technology" and [Product] = "Harmony Platform" then "Harmony Platform"
else [Practice]

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@Anonymous , new column in M like

if [Practice] = "Technology" and [Product] = "Agility Loyalty" then "Agility Loyalty" else
if [Practice] = "Technology" and [Product] = "FRMS" then "FRMS" else
if [Practice] = "Technology" and [Product] = "Harmony Platform" then "Harmony Platform"
else [Practice]

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.