MERGE Two Columns Into A Single Column
MERGE Two Columns Into A Single Column Input collection: myContactNames17 FirstName LastName Email Johnson Bruce [email protected] Field Sally [email protect...
- Published
- Reading time
- 1 min read
Before you start
Is this guide for you?
- Best entry point
- Power Apps
- Time investment
- 1 min read
Imported reference from Matthew Devaney's blog for learning purposes. Original: https://www.matthewdevaney.com/powerapps-collections-cookbook/merge-two-columns-into-a-single-column/. Author: Matthew Devaney.
MERGE Two Columns Into A Single Column Input collection: myContactNames17 FirstName LastName Email Johnson Bruce [email protected] Field Sally [email protected] Nyugen Sam [email protected] Waters Laura [email protected] Noble Jackie [email protected] Output collection: mySolution17 FullName Email Johnson, Bruce [email protected] Field, Sally [email protected] Nyugen, Sam [email protected] Waters, Laura [email protected] Noble, Jackie [email protected] Solution code: //Create a collection
ClearCollect(myContactNames17, { FirstName : "Bruce" , LastName : "Johnson" , Email : " [email protected] " }, { FirstName : "Sally" , LastName : "Field" , Email : " [email protected] " }, { FirstName : "Sam" , LastName : "Nyugen" , Email : " [email protected] " }, { FirstName : "Laura" , LastName : "Waters" , Email : " [email protected] " }, { FirstName : "Jackie" , LastName : "Noble" , Email : " [email protected] " } ); //Merge two columns code
ClearCollect( mySolution17, DropColumns( AddColumns( myContactNames17,
"FullName" , LastName& ", " &FirstName ), "FirstName" , "LastName" ) ); Code language: JavaScript ( javascript )
Tagged
Power Apps
Have a Microsoft 365 topic idea?
Share article suggestions, community session ideas, corrections, or real-world scenarios for future nextM365 learning notes.
Keep learning Microsoft 365
Explore more practical guides for SharePoint, Power Platform, Copilot Studio, migration, automation, governance, and security.
Continue learning
Related tutorials
Related questions
Related comparisons
Next action