> ## Documentation Index
> Fetch the complete documentation index at: https://www.integrate.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# ETL: Execute SQL

> The Execute SQL workflow component runs a SQL statement as a step in your workflow. Use it to perform database operations between package executions.

The Execute SQL workflow component runs a SQL statement as a step in your workflow. Use it to perform database operations between package executions.

## Overview

* Runs a single SQL statement against a database connection
* Commonly used for pre/post-processing: truncating staging tables, updating flags, running stored procedures
* Does not return data -- it executes the statement and reports success or failure

## Configuration

<Steps>
  <Step>Select a database connection.</Step>
  <Step>Enter the SQL statement to execute.</Step>
  <Step>Optionally use variables in the SQL statement with the `${variable_name}` syntax.</Step>
</Steps>

## Use Cases

* Truncate a staging table before loading data
* Run a stored procedure after a dataflow completes
* Update a status flag to mark a batch as processed
* Create or drop temporary tables between pipeline steps
