Get Inspire insights from former attendees in our AMA discussion thread on Inspire Buzz. ACEs and other community members are on call all week to answer!

Alteryx Designer Desktop Discussions

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

Error: Moving Batch Files

tko
6 - Meteoroid

Hi : 

 

I set up TWO batch files in the end of my work flow. 

 

In the end of my work flow, I will get few "full_path" going into a Good batch workflow, or a Bad batch workflow, or neither or both. 

 

1. if all the full_path go to Good Batch workflow, then the Bad batch workflow will error it out, becasue there is nothing for the batch file to move. 

 

2. if all the full_path go to Bad Batch workflow, then the Good batch workflow will error it out, becasue there is nothing for the batch file to move. 

 

3.  if all the full_path go to both Good Batch and  Bad batch workflow, it works fine. 

 

4. if all the full_path go to neither Good Batch and  Bad batch workflow (so not data coming in), both batch file will error it out. 

 

is there anyway to avoid the error, such as if there is nothing coming in to the workflow, it will just ignore it. 

 

I followed procedure to create the batch fiels 

--> http://community.alteryx.com/t5/Alteryx-Knowledge-Base/Batch-Files-in-Alteryx-Part-2-Moving-Files/t...

 

And I tried this method to solve my problem, but didn't work, becasue the batch flies can't get trigered 

-->https://community.alteryx.com/t5/Alteryx-Knowledge-Base/CS-Macro-Dev-Conditional-Processing-with-Det...

 

Thank you!

1 REPLY 1
KevinP
Alteryx Alumni (Retired)

@tko If I understand this correctly you are dynamically generating two batch files to move files based on if you have a "full_path" or not. The issue you are encountering is that when one of the two batch files doesn't receive any input the run command errors because the needed information to create the batch file isn't present. The only workarounds I can think of to this would be to use a conditional detour (as described in your second link) to bypass or execute the run command depending on if data is present or not. If you can't get this to work you could take steps to ensure the batch file always has something to execute so that it doesn't trigger an error.To be honest though I am not sure why you would need two batch files to accomplish this, and using a single batch file instead would ensure the batch file always has something to do.

Labels