I have a trigger setup to email me a copy of a PDF when it is added to a SharePoint site. This time two documents were submitted a few seconds apart. I got two emails with the same document attached. I verified in the site that the two documents are different, different names, different text.
Anyone have any idea what happened?
The trigger for the flow is SharePoint: When a document is created in a folder.
The next step is SharePoint: Get Document (Properties Only)
This step, I think, is the source of the problem. The settings for this step are:
The Top Count is set to 1. And since it the docs were uploaded a few seconds apart...
Any suggestions for correcting this problem?
Solved! Go to Solution.
Thank you for posting.
According to your description, you are encountering receiving duplicate files issue.
Actually, the issue is caused by upload order in SharePoint. Even though you upload two files together, the order is depending on SharePoint upload mechanism. It doesn’t mean the last updated file will be counted as first. So the top count configuration is meaningless.
Meanwhile, the action you used is not such suitable. The ‘get files (properties only)’ is normal used after ‘get files’ and will cause looping for each file. So to avoid order issue to get duplicate file, we’d better change ‘get files (properties only)’ to ‘get file property’ if this action is necessary.
But in your scenario, we can change flow as below:
Once tested, I’m able to get separate emails with different files attached.
Hope the content above may help you.
Best regards,
Anna
Thank you for posting.
According to your description, you are encountering receiving duplicate files issue.
Actually, the issue is caused by upload order in SharePoint. Even though you upload two files together, the order is depending on SharePoint upload mechanism. It doesn’t mean the last updated file will be counted as first. So the top count configuration is meaningless.
Meanwhile, the action you used is not such suitable. The ‘get files (properties only)’ is normal used after ‘get files’ and will cause looping for each file. So to avoid order issue to get duplicate file, we’d better change ‘get files (properties only)’ to ‘get file property’ if this action is necessary.
But in your scenario, we can change flow as below:
Once tested, I’m able to get separate emails with different files attached.
Hope the content above may help you.
Best regards,
Anna
The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.
Learn to digitize and optimize business processes and connect all your applications to share data in real time.