We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Retrieve the specific file from the sub folders.

stj1120
8 - Asteroid

Hi all,

 

I have a typical problem where I have one Employees folder and in this folder there are about 4 sub folders with the team members names. 

 

sreenivasateja_0-1603187502384.png

 

In each of these sub folders there will be CV, JD, and WA files. 

 

How can I access the specific files from each of these sub folders in alteryx? I know by using the Directory tool we will be able to retrieve all the files present in a folderbut, I don't know how to fetch a specific file present in the sub folders.

 

Could anyone help on this?

 

Thank you.

 

Best Regards,

Teja.

3 REPLIES 3
JosephSerpis
17 - Castor
17 - Castor

Hi @stj1120 if you tick on include Sub-Directories in the Directory tool it will find all the files in those sub folders. You can then use a filter tool to reduce the entire list of files to those files you need. Also you can use the file specification to look for certain filesname or file types as well. Once you have your list of files you can use a dynamic Input of Batch Macro to pull the data from those files into the alteryx workflow. This post showcases how to do pull data into the workflow with a dynamic Input and Batch Macro after you retrieve the list of files you are interested in.

 

Sub_Directoires.JPG

DavidP
17 - Castor
17 - Castor

Hi @stj1120 

 

With the Directory tool, you can use the file specification to specify the file name or file types you want to retrieve.

 

For instance Invoice2020*.xlsx will retrieve all xlsx files that start with Invoice2020.

 

You can be clever by using * (wildcard) in a a number of places to create your filters, for instance *invoice* retrieves all files that have invoice anywhere in the name, and so on.

 

DavidP_0-1603190979461.png

 

Qiu
21 - Polaris
21 - Polaris

@stj1120 
Directory Tool will output the file information.

If to get the data from each file, I usually go with the Input Data tools as attached.

1020-sreenivasateja.PNG

Labels
Top Solution Authors