Break on Error

Break on Error

An error has occurred in a workflow and it continues to run anyway??Sometimes that's all right, but only sometimes.

However, the default setting is that an error does not lead to cancellation. Of course, it is particularly annoying when an error occurs right at the beginning of a workflow and then it continues to run ( perceived) endlessly. If, for example, in a workflow like this, the Excel file cannot be read in for some reason, while access to the database works perfectly.

Es wurde kein Alt-Text für dieses Bild angegeben.

Okay, let's perhaps also look at the volume of data to be read here.

Es wurde kein Alt-Text für dieses Bild angegeben.

By default, the database table would now be read completely and the workflow would continue to be executed; in the end, no usable results would be produced.

Of course, you can now cancel the workflow by simply clicking "Stop".

Es wurde kein Alt-Text für dieses Bild angegeben.

However, this is only possible if you continue to watch the workflow after it has started and notice that there is an error - I don't do this in every case, in particular I like to let workflows that have been running for a longer period of time work unobserved.?

Es wurde kein Alt-Text für dieses Bild angegeben.

However, there is an option to set individually for each workflow whether it should be cancelled immediately in case of an error. In the workflow configuration, under Runtime, there is the option "Cancel Running Workflow on Error", which controls exactly this behavior.

Es wurde kein Alt-Text für dieses Bild angegeben.

If you select this option, the first error leads to the immediate cancellation of the workflow - subsequent steps are not even started. Here, too, a "Cancel" leads to the termination of the workflow, but this time an automatic one triggered by the setting.

Es wurde kein Alt-Text für dieses Bild angegeben.

This way you can avoid that an error in the workflow leads to faulty results!?

But this option can of course also be used for other purposes. Often a workflow only needs to be executed if a certain condition is met. Here you can use the TEST tool, which can be found in the Developer Tool Palette and which offers the option of checking one or more conditions. If a condition is not fulfilled, an error is output - in conjunction with the setting "Cancel Running Workflow on Error", this can be used to ensure that the workflow only continues to run if it is "successful".??

Es wurde kein Alt-Text für dieses Bild angegeben.

However, the TEST Tool has no Output Anchor, so a little trick is required. We can use a BLOCK UNTIL DONE tool here, to whose Output Anchor 1 the TEST tool is attached to execute the check, to Output Anchor 2 then hangs the "normal" subsequent processing that is to be executed if the check was successful. In the case of an unsuccessful condition, the workflow is aborted and the tools behind Output Anchor 2 are no longer processed.

Es wurde kein Alt-Text für dieses Bild angegeben.

The setting "Cancel Running Workflow on Error" thus gives us additional design options besides its actual main function!


#AlteryxAdventCalendar #alteryxace #alteryxinnovator #analytics

?


要查看或添加评论,请登录

Roland Schubert的更多文章

  • Time For Summary

    Time For Summary

    When I receive a new table or file, I always try to first get an overview. Usually by bringing an INPUT DATA tool onto…

  • A Little Bit More: Oversampling

    A Little Bit More: Oversampling

    When selecting data records, it is often simply a matter of selecting only the first (or last) data from a table…

    1 条评论
  • Building Groups Based on Relations

    Building Groups Based on Relations

    Grouping is not necessarily a very unusual task - customer groups always come to my mind spontaneously. Common…

  • Different Types of Correlation

    Different Types of Correlation

    I have to admit it - I intuitively tend to look for relationships between different data. And indeed, I often recognize…

  • Grouping Data

    Grouping Data

    Grouping data in some way is an essential part of day-to-day business for data analysts. Many people immediately think…

  • Comparing To Lists

    Comparing To Lists

    Long years ago, a DIY chain in Germany launched a discount campaign entitled "20% discount on all items - except pet…

  • Famous (or Not-So-Famous) Last Words

    Famous (or Not-So-Famous) Last Words

    Sometimes you just have to have the last word - the last word from a text field, of course. When it comes to "breaking…

    1 条评论
  • Year-To-Date Calculations

    Year-To-Date Calculations

    If you are working in Finance/FP&A/Controlling, calculating "Year to Date" (YTD) values is an essential part of your…

  • Compare Date and Time

    Compare Date and Time

    We often need data only for a specific period of time - a year, a month or a week, sometimes just a few hours, but the…

  • Sample or Random Sample?

    Sample or Random Sample?

    In Alteryx there are some tools that can be used for very different tasks and whose name can sometimes be confusing…

社区洞察

其他会员也浏览了