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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
unicorns
Helper II
Helper II

Conditional Column - take values from different columns if it exists

How could I write power query to achieve below? whichever column has value, it'll be listed in "Final ID" column.

If both ID and Identifier columns have values, then take ID column's value. 

 

 unicorns_0-1684971763403.png

 

unicorns_0-1684971635985.png

 

 

1 ACCEPTED SOLUTION
Ahmedx
Super User
Super User

pls try this

List.Max({[Id],[Identifier]})

Screen Capture #1167.png

View solution in original post

2 REPLIES 2
Ahmedx
Super User
Super User

pls try this

List.Max({[Id],[Identifier]})

Screen Capture #1167.png

Ritaf1983
Super User
Super User

Hi @unicorns 

Please to achieve your goal you can add a conditional column like on bellow picture:

Ritaf1983_0-1684981320750.png

Result

Ritaf1983_1-1684981382092.png

 

Link to sample file 

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

 

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
Feb2025 Sticker Challenge

Join our Community Sticker Challenge 2025

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.