Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.

Alteryx Designer Desktop Discussions

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

Avoid the Dynamic tool error if the Input file is not found

danbzz
6 - Meteoroid

I have a workflow that processes two types of files "separately" because their data needs to be cleaned differently and then joins them. However, it could happen that one of the two data sets is missing, but I would like to be able to run the workflow anyway and avoid the Dynamic tool error that I get in case the file is not found. I would like to avoid using Macros though. 

 

The logic of my workflow is not that complicated and looks like the following.

 

danbzz_0-1654693741821.png

 

Any help or tips would be highly appreciated!

 

7 REPLIES 7
IraWatt
17 - Castor
17 - Castor

Hey @danbzz,

I'm sure there must be a smarter work around but you can add in a dummy file. This ensures that there will be a column to join on so that the join doesn't error:

IraWatt_0-1654694256475.png

Give it a try

Any questions or issues please ask :)
HTH!
Ira

 

danbzz
6 - Meteoroid

hey @IraWatt - thanks for your reply! Unfortunately, the error is related to Dynamic Input not finding the file within the input folder, and not from the join. The workflow stops before it gets to that point (pls see below).

danbzz_0-1654695948357.png

 

 

This is because the 2 datasets can both be present at the same time, one missing and the other not, and vice versa. And in case one of them is missing, the workflow generates an error. Would you have any other ideas?

IraWatt
17 - Castor
17 - Castor

@danbzz you workflow in the configuration I gave will still run if the dynamic input tool errors. So long as this option in the runtime configuration is ticket it will still run.

IraWatt_0-1654696105929.png

You can check this be seeing if data is still being passed to the join if only one dynamic input has data.

 

danbzz
6 - Meteoroid

@IraWatt oh got it! So, basically, the workflow will run regardless of the missing files and will throw an error when completed, right? Wouldn't that be confusing? Do you think it is possible to customize the error message?

IraWatt
17 - Castor
17 - Castor

Yeah @danbzz that's the idea. I don't think its possible to overwrite or stop the Dynamic input from erroring however you can create you own message on top of it to explain:

IraWatt_0-1654765870030.png

 

. Have you considered using a directory tool to check the files exist before the dynamic input? 

danbzz
6 - Meteoroid

@IraWatt yeah, I am using the directory and filter tools to check the existence of the files before trying to open them with the Dynamic Input tool, but unfortunately, Alteryx keeps generating the error in case the file does not exists. I assume therefore that there is no way to avoid the error.

GMurphy
5 - Atom

I have the same need.

Labels