cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ajssbp
New Member

Sharepoint move file flow error

Hello,

 

I'm trying to make a flow that will run and move all files older than the specified date range to a subfolder called Archive.  Identifying the files works fine, but when the Flow tries to move the file(s) I get a Bad Request Error:

ajssbp_0-1642711715877.png

Here's the flow:

ajssbp_1-1642711775005.png

 

Any suggestions would be much appreciated.  Thanks.

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-yujincui-msft
Microsoft
Microsoft

Hi @ajssbp ,

 

You could try using the 'Identifier' as parameter in the Move File Action.

I have made a test and it seems that works fine on my side.

vyujincuimsft_0-1643014428479.png

vyujincuimsft_1-1643014550012.png

Result Screenshot:

vyujincuimsft_2-1643014641828.png

 

Best Regards,

Charlie Choi

View solution in original post

4 REPLIES 4
v-yujincui-msft
Microsoft
Microsoft

Hi @ajssbp ,

 

You could try using the 'Identifier' as parameter in the Move File Action.

I have made a test and it seems that works fine on my side.

vyujincuimsft_0-1643014428479.png

vyujincuimsft_1-1643014550012.png

Result Screenshot:

vyujincuimsft_2-1643014641828.png

 

Best Regards,

Charlie Choi

ajssbp
New Member

Hi @v-yujincui-msft Charlie

 

I think I may have two problems going on - Changing from ID to Identifier fixed some of the failures, but I'm still having some.  Is there a character limit on the file path/file name combined?  Some of the file names are long and combined with the path may exceed 255 characters.  When I test the flow it isn't identifying all the files (for example, it'll run against 100 files when there are 160 in the folder).  I can't figure out why I keep getting the BadRequest failure on some files.  Thanks.

v-yujincui-msft
Microsoft
Microsoft

Hi @ajssbp ,

 

Maybe you could try the following steps:

1. Click the ellipses on the “Get files (properties only)” Action.

2. Settings.

3. Pagination.

4. Click Done.

vyujincuimsft_0-1643160846822.png

vyujincuimsft_1-1643161049034.png

Here is an excellent article on how to deal with the collection size limits (e.g. SharePoint page size, Top count, Threshold):

https://alextofan.com/2019/08/22/how-to-get-more-than-5000-item-from-sharepoint-online-in-flow/ 

 

Best Regards,

Charlie Choi

ajssbp
New Member

Combination of changing from ID to Identifier and changing the pagination seems to have worked.  Thanks!

Helpful resources

Announcements
MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power automate tips 768x460 v2.png

Restore a Deleted Flow

Did you know that you could restore a deleted flow? Check out this helpful article.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Users online (1,966)