---
title: "Transition Expressions"
id: "transition-expressions"
project: "MES User Manual"
url: "https://docs.sepasoft.com/articles/user-manual/transition-expressions"
updated: 2026-09-28T16:41:22Z
---

# Transition Expressions

**Sepasoft MES Module Suite**

## Transition Expressions

Transition Expressions can be used to determine logical flow within Batch Recipes. , e.g., to determine which branch of multiple branches the execution should follow after an Or\_Begin control.

The execution engine waits for the Transition expression to evaluate to True before execution continues.

Some examples:

| Waits for the step named Kettle to complete before continuing the execution.<br><br><br><br>![](/resources/Storage/user-manual/transition-expressions/transition-expressions-2024-05-22-1.png) | Use Transitions to determine which branch of multiple branches the execution should follow after an **Or\_Begin** control.<br><br><br><br>Loop back if execute\_Count is less than or equal to '2'.<br><br>**Kettle.Execute\_Count &lt;= 2**<br><br>![](/resources/Storage/user-manual/transition-expressions/transition-expressions-2024-05-22-3.png)<br><br><br><br>* * *<br><br>Continue execution if Execute\_Count = '3'<br><br>**Kettle.Execute\_Count = 3**<br><br>**![](/resources/Storage/user-manual/transition-expressions/transition-expressions-2024-05-22-4.png)** |
| --- | --- |

Within Batch Recipes, add Transition after these elements:

* Phase
* And\_Begin
* And\_End
* Or\_Begin
* Or\_End

For information about when a transition is required, see [Batch Recipe Logic Validation](/articles/user-manual/batch-recipe-logic-validation).

A valid Transition Expression is one line of Python code referencing:

* Parameters: Batch Recipe (Procedure), Unit Procedure, Operation, Phase
* Ignition Tags
* Ignition Designer Project Scripts

| ![Information](/resources/Storage/user-manual/Info.png) | Auto Completion<br> <br>Intellisense autocompletes the available options under and object. Navigate the autocomplete-**intellisense** using the keyboard: arrows and space bar. |
| --- | --- |

| ![Note](/resources/Storage/user-manual/Note.png) | In **MES 3.81.12 SP5**, **MES 4.83.1 SP5**, and later, a Transition expression can name a parameter on the current logic or step without a step or logic identifier:<br>
Code

```
MyParam = True
```
<br>Step and logic paths are still valid, and the leading / is optional:<br><br>
Code

```
P2.Complete
/{}/P2.Complete
Procedure/P2.TargetTemp > 80
```
<br><br>See [Referencing Parameters in Batch Recipes](/articles/user-manual/referencing-parameters-in-batch-recipes).<br><br>On a Unit Procedure or Operation template, a transition that refers to a parameter outside the template, such as a Procedure parameter, is not flagged when the template is validated. That reference is validated when the template is used in a recipe. |
| --- | --- |

### Valid Operands in Transition Expressions

**Operands in Transition Expressions**:

* operands
* fixed values
* tag path
* Recipe, Unit Procedure, Operation, Phase references up and down the batch recipe structure.
* script reference or one line of code: the return value returns and replaces the script reference before evaluating the expression.

| Valid operands | Expression including script and tag path |
| --- | --- |
| AND<br><br>OR<br><br>()<br><br>=<br><br>!=<br><br>&gt;=<br><br>&lt;=<br><br>&gt;<br><br>&lt;<br><br>IS NULL<br><br>IS NOT NULL<br><br>NOT | To call a tag from a Batch Transition use {tagValue:TagPath} descriptor<br><br><br><br>{TagValue:[Default]Tank 101/Level} &gt;= 100.0 AND {Script:My Phase Complete}<br><br><br><br>P2.Operation IS NULL |
| **Expression including phase and procedure parameter** |
| ![](/resources/Storage/user-manual/transition-expressions/image2021-11-4_10-48-7.png) |
| **Expression including script reference** |
| To call a Batch Script from a Batch Transition, use {script:ScriptName} descriptor.<br><br>example: {script:My Phase Complete} |

**Sepasoft MES Module Suite**