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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Cannot create file sin...
Power Automate
Unanswered

Cannot create file since one already exists

(0) ShareShare
ReportReport
Posted on by 14

Hi

 

I have created a flow that send attachments to a specific Drive folder. It's triggered by a specific subject heading and all the attachments have exactly the same name. It works perfectly but when I set Outlook as the source instead of Gmail I get this error:

 

Cannot create file since a file with name '/Laps/Ranking.csv' already exists in the same folder.
clientRequestId: 30c75f90-426e-457a-820a-560cb0b48d5d

 

Changing the action from 'Create File' to 'Replace File' is not an option because I need all previous attachments to remain in place. As I said, this works from Gmail flawlessly - the flow creates the file in the folder without any issue, even if there are multiple files with the exact same name. Unfortunately, I can no longer use Gmail at work.

 

Any ideas about a solution?

 

Categories:
I have the same question (0)
  • VictorIvanidze Profile Picture
    13,073 on at

    Hi @Dan76, you can check if the file is already exists and if so delete it.  

  • Dan76 Profile Picture
    14 on at

    Hi Victor, I need to keep all the files in place in the Drive folder. I have a script that imports the files into a spreadsheet and it will update the sheet based on what is in the Drive folder. So if files are deleted that data will be missing from the sheet.

     

    I'm not sure why the exact same flow works with Gmail but not with Outlook.

  • Dan76 Profile Picture
    14 on at

    Dan76_0-1612004875343.pngDan76_1-1612004994221.png

    This is the configuration. If I set 'When a New Email Arrives" to Gmail, it works. If it's Outlook, it fails and gets the error I originally posted.

  • VictorIvanidze Profile Picture
    13,073 on at

    Hi @Dan76 , I mean to delete just before saving the file with the same name to avoid "file already exists" situation. 

  • Dan76 Profile Picture
    14 on at

    As a test I deleted the Drive folder and ran the flow again. It failed with the same error message - 'cannot create file since a file with the same name already exists in the same folder'. How can there be a file in the folder with the same name if the folder is empty?

  • VictorIvanidze Profile Picture
    13,073 on at

    Sorry I can't help here - it's a question to the Power Automate development stuff.

  • Verified answer
    Rei0116 Profile Picture
    on at

    Hi, I think you should raise a support ticket and provide more details. 

  • Dan76 Profile Picture
    14 on at

    Hi, have found a workaround to the problem. I used an expression that adds a timestamp to the file. This made each one unique, which avoided the error. In my original post I said that I had to keep all the files exactly the same (or the script in Google Sheets that pulls the files in from Drive would not work.) I was wrong, the script still works with the timestamp on it.

     

    Nonetheless, having to add an expression to a simple create file action is an extra step that I don't think should be necessary. I had to get help with the expression, my skill set does not include programming!

  • Viet_Luu Profile Picture
    3 on at

    @Dan76 Can you show me the expression to add the timestamp cause I am having the same issue

  • nickas Profile Picture
    228 on at

    Could you show us how you made it?

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard