SQL Script
Overview
A SQL Script is an AnalyticsCreator object that stores SQL for a defined repository, deployment, or workflow lifecycle stage.
Scripts are ordered within their type and can be enabled or disabled as required.
Function
Use SQL scripts to run controlled custom SQL before or after generation, deployment, or workflow processing.
Repository extension scripts are used to apply custom repository-side logic when that lifecycle action is run.
Types
Script type determines the lifecycle point at which the SQL is applied.
| Type | Use |
|---|---|
| Pre-creation script | Runs before object creation. |
| Post-creation script | Runs after object creation. |
| Pre-deployment script | Runs before deployment processing. |
| Post-deployment script | Runs after deployment processing. |
| Pre-workflow script | Runs before workflow processing. |
| Post-workflow script | Runs after workflow processing. |
| Repository extension script | Applies custom repository extension logic. |
Attributes
Attributes define the configuration, behavior, and relationships of the sql script entity.
| Attribute | Applies to | Description |
|---|---|---|
| Name | All script types | Identifies the script. |
| Script type | All script types | Determines when the script is executed. |
| Sequence number | All script types | Controls execution order within the script type. |
| Inactive | All script types | Prevents the script from running when selected. |
| Statement | All script types | SQL body executed at the configured lifecycle stage. |
How it is used in AnalyticsCreator
| Use case | Description |
|---|---|
| Extend generated processing | Run custom SQL around creation or deployment. |
| Prepare workflow execution | Run setup SQL before workflow packages. |
| Finalize workflow execution | Run cleanup or follow-up SQL after workflow packages. |
| Apply repository extensions | Execute custom repository-side scripts when requested. |
| Move script definitions | Import or export script structures when supported. |
Relationships
| Related entity | Relationship |
|---|---|
| Package | Workflow scripts run around workflow package processing. |
| Deployment | Deployment scripts run before or after deployment processing. |
| Repository | Repository extension scripts apply custom repository logic. |
| Macro | Script statements can use reusable logic where supported by the statement context. |
Where to configure
Configure or review this entity from the matching AnalyticsCreator user-interface area.