You can choose to configure SQL statements to run on a target before and after you write data to the target.
For example, you can alter the names of tables or schemas before or after you write the data to the target.
Configure the SQL statements when you configure a plan. You configure the SQL statements in the
Advanced Options
section of a plan. Click
Edit
to open the
Configure Expression
dialog box.
You can use $SCHEMA and $TABLENAME variables in SQL statements that you configure.
For example:
ALTER TABLE <target table name> RENAME TO $TABLENAME;
The SQL statement changes a specific table name in the target to the name that you specify in the $TABLENAME variable. When you include the statement in a plan, the workflow runs the SQL statement on the target and makes the change.
You can configure statements to run before or after you write data, or both before and after you write data to the target.