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.

Re: Stop workflow when Join tool has mismatched value shown in L and R anchor

Lien_Dao
6 - Meteoroid

Hi Alex, 

Thanks for your reply, I read up on the Message tool but didn't really know how to use it. Attached is screenshot of that particular workflow, where i have Test tool flagged out the breaks based on the number of record count from L+R >0. In the case of Test tool fails like this, I need to export out the output of the Union tool to an excel file and save it in a shared drive location for investigation. 

 

 

 

 

7 REPLIES 7
diegosantos
8 - Asteroid

Hi @Lien_Dao 

 

You can put the test tool into a control container and after that look for any MessageType = Error and save it in a shared drive location for investigation.

 

Stop workflow when Join tool has mismatched value shown in L and R anchor.yxmd.png

nagakavyasri
12 - Quasar

Click on the 'Test' tool to see the exact error message.

 

Screenshot 2024-09-16 130609.png

TUSHAR050392
11 - Bolide

@Lien_Dao Have you tried using the error message tool as I think it will do the same thing and is easier to configure. Here is the documentation - https://help.alteryx.com/current/en/designer/tools/interface-tools/error-message-tool.html#error-mes... 

KGT
11 - Bolide

You can't set it up to be "On error, export this". However you can write that data regardless and then only check it if the test fails. You can set it up to continuously overwrite etc. The main thing to take into account, is that will result in data sitting somewhere, and so make sure that's not a security risk.

Lien_Dao
6 - Meteoroid

Thanks @diegosantos @TUSHAR050392 @KGT @nagakavyasri  for your advices. I have settled with the attached workflow where I used BUD, Filter, Test and Output tools to get what I need.

 @diegosantos I tried control container but did not really know how to configure it correctly to get the same result, if you could demonstrate using the attached workflow it would be very much appreciated. Thank you!

diegosantos
8 - Asteroid

Hi @Lien_Dao 

 

I notice that your WF don't save the "Final matched output". If you needs both outputs: "Final matched and Mismached", you need make a little ajust in your WF (as bellow image):

Error_2.yxmd.png
Notice that in that case, you don't need the "test tool" and then "Block Until tool".

But if you needs catch the error message produced by your "test tool" you'll need put that into a control container, but i think that isn't what you want.

Lien_Dao
6 - Meteoroid

Hi Diego, I forgot to mention how I would like to design my workflow, below are the steps:

  1. Join data from 2 input files
  2. Check mismatched data after joining, if there is any, write output file named "Mismatched output" showing all mismatched data into a shared drive location, then stop workflow with error "Unmatched data" (not sure if end-user will see this error message in Server though, but once they see Mismatched output file generated in their folder, they will know there is mismatched data for their investigation and resolve before rerun the workflow to get the final matched output).
  3. If there is no mismatched data, workflow continues, all joined data will be written to another output file named "Final matched output" and saved in a shared drive location. The output for step 2 will not be generated. 

I used test tool and set the Runtime to cancel running WF when error, but use BUD to set the order of the WF so the mismatched output will be generated first before the WF stop running due to error. Hope this clarifies. 

 

Cheers

Lien

 

Labels