Showing results for 
Search instead for 
Did you mean: 

Alteryx designer Discussions

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

Output Selection Switch via Constant


Hi all,


Struggling with this one a bit, so hoping for someone to take pity on me. :)


I have written a basic macro that takes a constant from the work flow, and based on that result, the data is pushed to a different output channel. The issue I'm having is that I use Drop and overwrite in the output tool properties, so although it pips the data where I'd like it to be, it also wipes out the data on the others.


Is there a way I can put a condition to halt the process within the macro so the output doesn't fire?


Any help would be greatly appreciated.


Output Switch.JPG

@JimBow Can you describe/screenshot/send over a dummy version of the workflow that calls this macro? Off the top of my head, my suggestion would be to change your output tool configuration to Take File/Table name from field. Then you would have a formula tool before the output tool to set the field that the output tool uses for the filename. That way when you have 0 zero records, it won't overwrite your file.


All that being said, I may have a different approach if I had a better feeling for what you're trying to do.