web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Filing documents in si...
Power Automate
Unanswered

Filing documents in similar name folders (efficiency)

(0) ShareShare
ReportReport
Posted on by 2

Hi

I hope you can suggest an alternative approach for this problem, as what I have created is ridiculously inefficient.

 

I have a folder (in SharePoint) of files (Word documents) with employee names in the filename.  I want to automate the placement of these files in their staff folder (also in SharePoint).  Unfortunately, the folders may or may not match exactly the names in the document - for example, "Surname Firstname" or "Firstname Surname", and this list is managed by others.

 

  1. The workflow I made gets the contents of the Staff Folder and filters the array for IsFolder?.
  2. For each of these folders, an Apply to Each separates the Folder name into two strings (the first and last words)
  3. Within this Apply to Each, each document filename is searched for both strings
  4. If there is an AND match, some additional elements check if the correct SubFolder has been made and moves/copies the file to the correct SubFolder.
  5. If there is no match, the flow ends.

There are probably too many loops within the Apply to Each's which are taking the time, but this takes hours and hours for 125 files.

 

Thanks for any alternative approaches.

Mike

Categories:
I have the same question (0)

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 598

#2
Valantis Profile Picture

Valantis 477

#3
Vish WR Profile Picture

Vish WR 370

Last 30 days Overall leaderboard