Pre-workflow

Overview

Pre-workflow scripts are custom SQL steps that run before a workflow package starts its assigned package activities. Use this script type for workflow-level preparation, such as initializing control data, preparing staging conditions, setting runtime values, or validating prerequisites before the workflow begins.

Function

Use Pre-workflow when the SQL logic belongs at the beginning of a workflow package rather than during deployment or after the workflow finishes. Scripts in this group are ordered by sequence number and then by script name in the navigation tree.

Pre-workflow uses the shared Define script page. The editor stores the script type, script name, description, sequence number, inactive flag, SQL text, and workflow-package assignments. The package grid is visible for this type so the script can be assigned to the workflow packages where it should run.

When workflow automation is generated, assigned pre-workflow scripts are grouped into an initial script step. The first package activities in the workflow wait for that step to complete before they start.

Access

The Scripts branch contains a Pre-workflow scripts node. Its context menu provides List pre-workflow scripts and Add pre-workflow script, both preselecting the Pre-workflow script type.

How to access

Navigation tree

Scripts -> Pre-workflow scripts -> List pre-workflow scripts, or Add pre-workflow script

Toolbar

Scripts

Diagram

Not direct. Use the Scripts list or navigation tree.

Visual element

Define script -> Script type -> Pre-workflow

Screen overview

IDPropertyDescription
1Script typeSelects the SQL Script type. For this page the selected type is Pre-workflow.
2NameDefines the script name. Save validation requires a non-empty value.
3DescriptionStores the optional script description shown in the script list.
4Sequence numberControls ordering inside the Pre-workflow script group. A non-numeric value is rejected during validation.
5InactiveStores whether the script is disabled without deleting it.
6OriginalShows the editable SQL script text.
7ParsedShows the macro-parsed preview of the SQL script in a read-only field.
8ScriptContains the SQL body. Save validation requires a non-empty script.
9PackageLists workflow packages that can run this pre-workflow script.
10RunAssigns the script to the selected workflow package. Clicking the Run column header toggles all visible assignments.
11CancelReturns to the previous page without saving changes.
12SaveValidates the script fields, stores the SQL Script, saves the workflow-package assignments, and refreshes the navigation tree.

List behavior

List pre-workflow scripts opens the script list already scoped to Pre-workflow scripts. The list can filter by script name, shows Name, Type, and Description, and opens the Define script page when a row is double-clicked.

The New button opens a new script with Pre-workflow already selected. Delete removes the selected script after confirmation. The up and down buttons swap sequence numbers only between scripts of the same script type.

Related topics