transformations:halt
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
transformations:halt [2020/02/14 03:51] – dmitry | transformations:halt [2023/10/13 21:38] – [Warn and continue mode options] craigt | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ===== Halt on condition | + | {{ transformations: |
+ | ====== | ||
+ | Category: Workflow / Internal \\ | ||
- | This action | + | \\ |
+ | =====Description===== | ||
+ | This action | ||
- | The purpose of this action is to monitor | + | \\ |
+ | =====Use cases===== | ||
+ | *Monitor | ||
+ | *When working with Catalog items, Halt or Warn when data is outdated or possibly incomplete. | ||
+ | *In workflows, signal potential data quality issues and help to investigate errors. | ||
- | **Example** | + | \\ |
+ | =====Action settings===== | ||
+ | ^Setting^Description^ | ||
+ | |Mode|Options: | ||
- | Let's assume we expect amounts | + | \\ |
+ | ====Halt mode options==== | ||
+ | ^Halt mode ^Description ^ | ||
+ | |Halt if table is empty|This option stops the action chain and displays an error if the dataset is empty at the point of the Halt action.\\ | ||
+ | |Halt if table is NOT empty|This option stops the action chain and displays an error if the dataset is NOT empty at the point of the Halt action. | ||
+ | |Halt if the condition is true for EVERY row|The option stops the action chain if the entered condition evaluates to TRUE for every row in the dataset at the time of the Halt action.| | ||
+ | |Halt if the condition is true for ANY row|The option stops the action chain if the entered condition evaluates to TRUE for any row in the dataset at the time of the Halt action.| | ||
+ | |Error message< | ||
- | Before transformation: | + | < |
+ | \\ | ||
+ | ====Warn and continue mode options==== | ||
+ | ^Warn mode ^Description ^ | ||
+ | |Warn if table is empty|This option displays a warning and continues if the dataset is empty at the point of the Warn action.\\ | ||
+ | |Warn if table is NOT empty|This option displays a warning and continues if the dataset is NOT empty at the point of the Warn action. | ||
+ | |Warn if the condition is true for EVERY row|The option displays a warning and continues if the entered condition evaluates to TRUE for every row in the dataset at the time of the Warn action.| | ||
+ | |Warn if the condition is true for ANY row|The option displays a warning and continues if the entered condition evaluates to TRUE for any row in the dataset at the time of the Warn action.| | ||
+ | |Warning message< | ||
+ | |||
+ | < | ||
+ | |||
+ | |||
+ | \\ | ||
+ | For either of the " | ||
+ | |||
+ | |||
+ | \\ | ||
+ | =====Remarks===== | ||
+ | The condition must return either TRUE or FALSE for each row. If for some reason it returns an error then the action will also fail.\\ | ||
+ | |||
+ | If the condition is global (i.e. doesn' | ||
+ | |||
+ | |||
+ | The error message can be customized to provide more insight into the cause of the interruption. | ||
+ | |||
+ | \\ | ||
+ | =====Examples===== | ||
+ | **Example: | ||
+ | |||
+ | **Source table:** | ||
^Province | ^Province | ||
- | | ON | 1000| | + | |ON | 1000| |
- | | BC | #N/A | 187.5| | + | |BC | #N/A | 187.5| |
- | | QC | 2000| 270| | + | |QC | 2000| |
+ | \\ | ||
+ | **Action parameters (Halt mode):** | ||
+ | > Halt mode is "Halt if the condition is true for ANY row" | ||
+ | > The condition is "not isnumber([Amount])" | ||
+ | > Choose "Do NOT halt" if the dataset has no rows | ||
+ | |||
+ | This will make the action stop project execution because one of the values in column " | ||
+ | |||
+ | \\ | ||
+ | **Action parameters (Warn and continue mode):** | ||
+ | > Warn mode is "Warn if the condition is true for ANY row" | ||
+ | > The condition is "not isnumber([Amount])" | ||
+ | > Choose "Do NOT warn" if the dataset has no rows | ||
+ | |||
+ | The action will display a warning and continue project execution because one of the values in column " | ||
- | Defining a condition as follows | ||
- | not isnumber([Amount]) | ||
- | will make the action stop project execution, because one of the values in column Amount is not number. | ||
- | ===Notes=== | + | \\ |
- | The condition must return either TRUE or FALSE for each row. If, for some reason, it returns | + | ====Community examples==== |
+ | * [[https:// | ||
+ | * [[https:// | ||
+ | * [[https:// | ||
+ | * [[https:// | ||
- | If the condition is global (i.e. doesn' | + | \\ |
+ | =====See also===== | ||
+ | * [[transformations: | ||
+ | * [[transformations: | ||
+ | * [[transformations: | ||
- | **See also:** | ||
- | * [[syntax: |
transformations/halt.txt · Last modified: 2023/10/13 21:38 by craigt