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
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
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!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.