Alteryx Designer Desktop Knowledge Base

Definitive answers from Designer Desktop experts.

Error: Can’t find the file: “[path\FileName]”. Make sure the file path is correct.

lepome
Alteryx Alumni (Retired)
Created

Environment Details


If a workflow fails because a file was not found, it can be discouraging.  In this article, we cover some of the best practices to prevent this error as well as some troubleshooting tips if it occurs despite best practices being followed.


 

Error: Can’t find the file: “[path\FileName]”. Make sure the file path is correct.

In versions prior to 2021.1.4, you will see the shorter message

Error: File not found "[path\FileName]"
  • Alteryx Designer or Alteryx Server or Alteryx Analytic Hub
    • All versions
  • This error can occur associated with a range of tools, but the most common are Input Data, Output Data, or Dynamic Input tool.


Cause


Alteryx cannot access one or more files that the workflow requires.



Resolution


First, verify that the file is specified correctly in the tool.

  1. Check that the file is in the expected location.
  2. Verify that the file name has been specified accurately, including file type extension.

Next, make sure that Alteryx is configured to have access to the location.

  1. In the above example image, the path to the desired workflow includes a mapped drive letter (Z:)  This is not the best way to designate a path when writing a workflow.  Instead, best practice is to use a UNC path.  A UNC path has a format that gives the hostname as well as the directory structure in which the desired file is located, for example 
     \\HostnameDOTdomainDOTcom\MainDirectoryName\SubDirectories\Filename.csv
     
  2. If you have used a mapped drive letter instead of a UNC path, the workflow will probably run correctly from your desktop Designer because you are running from your own account, but this is not the best practice because if you ever share your workflow with a colleague or schedule it to run automatically or publish it to a gallery, you'll find that running the workflow in the new environment causes it to fail.  You can change the paths in your workflow using Options > Advanced Options > Workflow Dependencies.

     
  3. You can use the All UNC button to change the paths to UNC paths, and if you desire, you can also test the location to confirm.   Click OK to make the change in the workflow.


     
  4. In the scenarios noted above, the colleague or the AlteryxService must have permission to access network shared resources, even with the UNC path.  There is more information on configuring Desktop Automation or Server to grant appropriate permissions in other articles.

 More subtle considerations

  1. The path length cannot be longer than 260 characters.
  2. If the workflow is running from a gallery or has been scheduled, then there are a few more restrictions.  That is covered in a separate article:  Error: File not Found in Staging Directory

 

Additional Resources

Comments
jacob_kahn
12 - Quasar

This is a simple and easy path for troubleshooting. Thank you @lepome for taking the time to write this up. Definitely something 

I'm going to reference.

 

Jacob

https://www.linkedin.com/in/jacob-kahn-/ 

stuabs19
5 - Atom

What is the correct syntax for a sheet within an Excel file?

patrick_digan
17 - Castor
17 - Castor

@stuabs19 For an excel file, you can do something like this:

file.xlsx|||sheet name 1

You can also just use 1 pipe instead of 3 and alteryx will convert it to 3 pipes.

mschmeiser
7 - Meteor

What is the correct syntax for a zip file that contains a sub-folder and file? 

I am using the anaytic app to make the path dynamic. Is the 260 character limit calculated with the '%question.fieldname%' variable name or the dynamic value of the fieldname input by the user?