cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Digital
Level 8

Create new table from several columns in existing collection

I want to take several columns from a data source and put them in a new collection under a single column. For example the three items in column A, B, C would become three data items under a new column in the new collection.

 

colSourceCollection

           URL1                 URL2                     URL3

www.url-one.com | www.url-two.com | www.url-three.com

 

colNewCollection

 

URL

---------------

www.url-one.com

www.url-two.com

www.url-three.com

 

I've tried using GroupBy and AddColumns but can't get the result I'm looking for.

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Dual Super User
Dual Super User

Re: Create new table from several columns in existing collection

Hey @Digital 

 

Can you try to use the below expression:

Clear(colNewCollection);ForAll(colSourceCollection,Collect(colNewCollection,{Value:Url1},{Value:Url2},{Value:Url3}))

 

Hope this Helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

3 REPLIES 3
EricLott
Level 10

Re: Create new table from several columns in existing collection

You'll use AddColumns() and then Concatenate() to create the string.
Digital
Level 8

Re: Create new table from several columns in existing collection

@EricLott ,

 

Thanks for the reply.

 

So I should use AddColumns to concatenate the contents of each URL column. How would I then built a collection from the contents of the added column? Split perhaps?

 

I'm surprised there isn't a simpler way of taking data from several columns and putting into a single column table/collection.

 

Cheers

Highlighted
Dual Super User
Dual Super User

Re: Create new table from several columns in existing collection

Hey @Digital 

 

Can you try to use the below expression:

Clear(colNewCollection);ForAll(colSourceCollection,Collect(colNewCollection,{Value:Url1},{Value:Url2},{Value:Url3}))

 

Hope this Helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

Helpful resources

Announcements
thirdimage

Power Apps Super User Class of 2020

Check it out!

thirdimage

New Badges

Check it out!

thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Solution Authors
Top Kudoed Authors
Users online (4,855)