cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
JohnLambert
Level: Powered On

Collect response - get Id of created records

Hi,

I need to save collection to DataSource (SharePoint Online) and then get ID's of these records from SharePoint Online.

I have tried syntax like "Collect(CreatedTable, Collect(SharePointList, LocalTable))", but it collects all records to "CreatedTable" from SharePoint List. Is there anyway to achieve this? With single record, the case is simple - I use Set(Var, Patch(SharePoinntList, Record)) and I get all details about created record. But how to handle the whole collection?

1 REPLY 1
emh
Level 8

Re: Collect response - get Id of created records

Hello John,

If you are using Patch to update SharePoint then you only need to make a slight modification to your Patch command and place the results of your Patch into a new Collection. Then you may access this new Collection and extract the id.

ClearCollect(LastSharePointUpdates, Patch( your patch syntax)) );

Collection LastSharePointUpdates will have the data you seek.

Hope this helps.

Helpful resources

Announcements
firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

SecondImage

PowerApps Monthly Community Call

Next Wednesday, August 21st at 8am PDT

Top Community Contributors for July 2019

Top Community Contributors for July 2019

Let's thank our top community contributors

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

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

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

FifthImage

Dynamics 365 and Power Platform April 2019 Release notes

Features releasing from April 2019 through September 2019!

SixthImage

Power Summit Australia 2019

August 20-23rd 2019

Users Online
Currently online: 278 members 4,024 guests
Please welcome our newest community members: