Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.
Community is experiencing an influx of spam. As we work toward a solution, please use the 'Notify Moderator' option on the ellipsis menu to flag inappropriate posts.

Alteryx Designer Desktop Discussions

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

Cancel workflow on error still triggers downstream macro

sid
6 - Meteoroid

Hello

 

 I have a macro where i have Success and Failure Outputs. When a job fails, the Success output gets 0 records. I then pass that to a message where i want it to fail on 0 records . If not 0 then it should trigger the next macro. I have cancel workflow on error set. But what happens is it triggers the downstream macro and then throws the error. How do i overcome this? 

 

Output LogOutput LogWorkflowWorkflowMessage ToolMessage Tool

6 REPLIES 6
MarqueeCrew
20 - Arcturus
20 - Arcturus

@sid,

 

How about a different approach?

 

Workflow runs ....

 

You can create an event for errors and an event for no errors.  Without errors, you run the next workflow.  With errors, you stop.

 

https://community.alteryx.com/t5/Alteryx-Knowledge-Base/Scheduling-Workflows-Using-Event-Run-Command...

 

Cheers,

Mark

Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
sid
6 - Meteoroid

@

 

 

the macro that i am running is a generic macro that will run a workflow/app .So if i have a sequence of macros i dont want to run the downstream macros if the previous one failed. I saw other solutions with message and cancel workflow but for some reason it runs all the macros first and then it throws the error. 

fnoahbiro
6 - Meteoroid

Did you ever resolve this? I am having the same problem and it is driving me insane.

SeanAdams
17 - Castor
17 - Castor

Hey @fnoahbiro 

If I understand you correctly you have a series of macros in order, and you only want  to run macro 2 if macro 1 succeeded?

 

I think that the way round this is instead of using standard macros, use Batch Macros - so if it fails, it doesn't pass on control to the next one.

 

If you can mock up a simple version of the problem, we can iterate quickly on this together!

I have found that if you change the mesage type from error to error- and stop passing records through this tool it works. It seems to be a bug that when only producing the error the workflow does not stop.

Joel_AkajeMacauley_0-1670510726699.png

 

I have found that if you change the mesage type from error to error- and stop passing records through this tool it works. It seems to be a bug that when only producing the error the workflow does not stop.

Joel_AkajeMacauley_0-1670510785903.png

 

 

Labels