cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Export PowerApps collection to Sharepoint list for multiple users in parallel

(I've posted this query on the Power Automate community, but figured it might be applicable here also. Apologies if this is the wrong place.)

 

I am trying to figure out a collection export solution using a flow connected to a PowerApps App. 

 

The aim is to export the collection on a 'per user' basis. 

Let's suppose users Harry and Ben both have access to use the app.

 

Harry and Ben are viewing the following collection, col_Items: 

Items

Bugs

Bats 

Bears

 

They want to export the collection as an Excel table. This should, of course, look like the following, for both Harry and Ben:

Items

Bugs

Bats

Bears

 

This is currently achieved by exporting the collection to an existing sharepoint list, using PowerApps' built-in patch() function.

(Then, the list is exported to an excel doc, but that's not what I want to focus on here.)

 

If Harry and Ben both click on the button that calls the patch() function at the same time, then the resulting Sharepoint list could become jumbled, and/or it often combines the two requests: 

Items

Bugs

Bats

Bats

Bugs

Bears

Bears

 

Harry and Ben then receive the above list, containing 6 items. This is obviously not what they wanted; they only wanted 3 items each.

(Yes, I've double checked, and it's definitely the sharepoint list that's to blame. The subsequent Excel export seems to process the list OK.) 

 

At the root of this issue is a simple problem: Currently, I am trying to process both requests through the same sharepoint list. 

 

Is there any way to approach this in a 'parallel processing' manner? Ideally, I'd like to create separate sharepoint lists for each request, and then delete them once they are exported to Excel.  Of course, this could be done manually with one sharepoint list pre-created per registered user, but we could have 100s of users and this isn't going to be ideal! 

 

Is there any way to achieve this? Perhaps sharepoint lists are the wrong approach for this?

 

Thanks. 

 

8 REPLIES 8
Highlighted
Super User III
Super User III

@Anonymous 

Yes, you will have issues with multiple users attempting the same operations on a list.  The only real way to resolve that is to implement a refresh prior to Patch/update, and even then, you need something in there that will validate duplicates.

You could offload this to Flow of course, but again the same complexity.

My question would be - since it seems like your goal is an Excel file - why not just create the Excel files from Harry and Ben based on their data?

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!
Highlighted
Anonymous
Not applicable

Thanks-some good food for thought there. Can you please explain what you mean by ‘based on their data’? As in, their username, email etc?

The actual data to be exported originates from a static Excel table within the app. It is used to create a collection which, in turn, patches the Sharepoint list. In this way, the data itself is not inherently associated with either user, although different users may wish to export different portions of the excel table as individual collections.

From what you’re saying, it sounds like there are better approaches than my current method. Can you please just clarify the above?

Thanks 🙂
Highlighted

@Anonymous 

It just seemed like your ultimate goal was to export to an Excel file. 

What I meant by "based on their data" was - are they entering in information that then would go to SharePoint and then be exported to an Excel file?

I'm not sure I understand in your context, why there would be collisions of data for a user.  It seemed, based on your description, that each user data was unique and then exported to Excel.

 

Anyway, my suggestion was, if they are completing information in the App that then goes to a unique Excel file (ultimately, after the pass through SharePoint) then why not go direct to Excel and skip SharePoint and all of the potential issues that come from that?

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!
Highlighted
Anonymous
Not applicable

Thanks for clearing that up. Sorry if I wasn’t clear; the reason I’m exporting the data to Sharepoint as a first step is that PowerApps does not currently support direct exporting to Excel. Very annoying!

The users aren’t actually entering in any information. Rather, they simply have access to view data in the app. This data comes from a static excel table, viewed via a collection.

But they may wish to export the data (ideally, they’d just download it, but there’s no function for that) the data for use in other applications, eg Excel.

Hence, I need to make sure there’s a way they can do this.

The reason for the data clashes is that they are exporting data into the same destination. This is currently a Sharepoint list but, as you state, it would ideally be an excel file if Microsoft permitted direct Excel exports.

The Sharepoint list is actually deleted once the info exported from powerapps (step 1) is copied to Excel (step 2). But if 2 users try to export at the same time, then the Flow exports both sets of data into the list, creating a combined list that contains some data that is irrelevant to user 1, and likewise for user 2.

So there is no unique ‘user data’ entered into the list as such. Powerapps simply exports data that the user wishes to view, not data that the user has entered into the app.

Is that any clearer?

Thanks for the help so far.
Highlighted

@Anonymous 

Thanks for the clarification.

One thing you might want to look at first as an option is the PlumSail Documents Connector.  This connector will let you create an Excel file from your PowerApp through Flow.

Although the Plumsail connector is via subscription. The price is low enough that it may return on the investment quickly as opposed to you trying to jump through all the steps that you are for just a simple Excel file creation.

Something to look at as it would eliminate all the interim steps you are going through and not require any manual interaction along the way.

 

 

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!
Highlighted
Anonymous
Not applicable

Thanks, I'll look into that. Though it's peculiar that Microsoft's lack of any form of 'download collection as excel/csv' feature creates a market for a third party to step in.

 

Appreciate the help.  

Highlighted

@Anonymous 

Yes, it does for sure!

 

To be clear, you can (through PowerApps combined with Flow) create these type of files.  It's not a cakewalk though and involves a lot of steps.  What I find nice about PlumSail Documents is that it just does it.  Still involves some Flow, but you have a high level of control over how you want your final product to appear.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too!
Highlighted
Helper V
Helper V

Export and Import

Automate - PowerShell, Flow Management and Flow Studio

Power Platform Solutions

Subscribe to multiple SharePoint Lists with One Flow.

 

I hope this is helpful.

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Top Kudoed Authors
Users online (8,113)