cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
hpkeong
Community Champion
Community Champion

PATCH a Batch of Records at One Time

Hi PG:

 

Enter data and Save (Patch or SubmitForm) takes about 10-15 seconds sometimes due to Slow Internet in our region.

Is there any way to:
- Collect data, say for 20 (into Collection)

- Patch or SubmitForm, on one click.

This will improve our slow connection problem.

 

Please help us in our situation. We are not from USA and other advanced country.

TQ

hpkeong
5 REPLIES 5
LisaChen1226
Microsoft
Microsoft

Hi PG,

 

From your description, my understanding is that you want to create multi records at one time.

You can create multi records at one time using the following:

 

Collect(Destinations, { {Cities: “Beijing”, States: “China”}, { Cities: “NY”, States: “America”}....)

 

Or you can:

Insert two input text control, and rename them as  'City' or 'State', 

Insert two input text control, and rename them as  'City1' or 'State1', 

......

Insert a Button. Set its OnSelect property to the following function:

Collect(Destinations, {Cities:City!Text, States:States!Text}, {Cities:City1!Text, States:States1!Text} ...)

 

Reference:

https://powerapps.microsoft.com/en-us/tutorials/create-update-collection/

 

Best Regards,

Lisa Chen

Hi Lisa:

 

Well, Brian has shared before and we are discussing over PATCH.

Collection is not an issues (anyway thanks). Collection is alwasy temporary into temp file at no delay.

We can even SaveData and Export as XML and Import Again (this is useful for Backup) which used during Siena era.

 

The main issues are: Patch for each record takes long time (> 5 seconds or more for slow connecting speed country, like mine). So, Brian has 2-records patching examples.

My case, is it is the USER decides when to Patch a batch of record to expedite the whole saving proces to cloud.

 

I wish PowerApps Staff has some more idea or it is impossible?\

 

TQ Lisa

hpkeong
mr-dang
Community Champion
Community Champion

Thank you for the example on how to collect multiple rows--I learned something new!

 

Maybe the same pattern can be applied to Patch for multiple rows. Or is it already implemented--I'll try now.

Microsoft Employee
@8bitclassroom
mr-dang
Community Champion
Community Champion

I tried:

Patch(source,Defaults(source),{column: data1},{column: data2})

Collect(source,{column: data1},{column: data2})

 

Collect will save both of those rows. Patch will overwrite data1 with data2 because they're both tied to the new row "Defaults(source)".

 

If Patch could somehow make a relationship between an existing collection and a datasource, I think it would work more effiiciently than specifying the column again and again as in the Collect example above.

Microsoft Employee
@8bitclassroom
Tamas
Regular Visitor

Hi Mr dang


I have a similar issue when 2 or more users want upload their data at the same time to cloud, second user always overwrite first users data.
Did you find solution for your problem?

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (3,158)