Alteryx Designer Desktop Discussions

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

Check file exists for dynamic file name

aeolus187
8 - Asteroid

Hi alteryx engineer,

 

I used fileExists function to check if file exist, but this function only work for the fixed file name, if file name is dynamic and i used * as wild card for the file name, it wont return the expected result.

 

any solution for dynamic file name?

 

suppose we have time stamp within the file name and it is not fixed, how could i check those file exists?

Thanks 

4 REPLIES 4
flying008
15 - Aurora

Hi,@aeolus187 

 

Dear , Maybe you can give a sample data to show dynamic name?

like this:

FileExists([Engine.WorkflowDirectory])
messi007
15 - Aurora
15 - Aurora

@aeolus187,

 

Have you tried using input directory and filter tools :

In the example below I'll read the file that have Excel at the end of the name :

 

messi007_1-1650875389984.png

1- I used an input directory

2- RegExMatch in order to fix the patern

messi007_2-1650875448712.png

 

Attached the workflow,

Hope this helps!

Regards,

 

 

 

aeolus187
8 - Asteroid

@messi007 

 

Hi messi  

suppose we have file name like “client 220412-12:20:31.xlsm”,   12:20:31 is dynamic and I checked the file using  “client 220412*.xlsm” but didnt return expected result

 

aeolus187_0-1650888410924.png

 

 

messi007
15 - Aurora
15 - Aurora

@aeolus187,

 

Please update the filter with the formula below :

 

messi007_0-1650892197750.png

 

Hope this helps,

Regards,

LogoPrime.png

Labels
Top Solution Authors