SQL Data Check Dynamic Action

About

The SQL Check Action object can be used to check data queries in the database, to ensure that data integrity and ensure that results are returned as expected.

Metadata tab

SQL Data Check Action - Metadata tab
 

  1. The Write Variables option ensures that the “Package Action” logs the variable values into the “Action vars before log file” before the action is executed and logs the updated variable values into the “Action vars after log file” after the action completes.
  2. This option is typically used for debugging and is not recommended in a production environment.
  3. It can be globally disabled through the options dialog .

Parameters tab

SQL Data Check Action - Parameters tab

Tips

  • The “Replace Variables” parameter is used to substitute variables within SQL statements.
  • When the “UseEmbeddedSQL” is set to True EmbeddedSQL is used, otherwise SQL Script/Lookup is used.
SQL Data Check Action - UseEmbeddedSQL Parameter

Selecting Script

SQL Data Check Action - Editing SQL Data Check Parameter

Editing Script

SQL Data Check Action - Editing SQL Embedded Script Parameter

Selecting Connection

SQL Data Check Action - Editing SQL Data Check Connection Parameter

Variables tab

The Variables tab defines the variables to be updated during the action’s execution.

SQL Data Check Action - Variables tab

date: 2026-06-21

Execution log tab

The Execution log tab is populated after the action is executed. Double click on the row to view the log.

SQL Data Check Action - Execution log tab

Example

SQL Data Check uses SQL scripts to check data in the database.

For example, the user may write the following SQL:

Select count(*) from table
  • Execution is successful if the value of the first field of lookup query is more than 0
  • Execution fails if the value of the first field of lookup query is equals to 0 or less than 0 or field type is not numeric.

Calculated parameters example

Pascal

SQL Data Check Action - Calculated Parameter example - Pascal
  Script

begin
 if DayOfWeek(Now)=3 then
    begin
     Result:=1917;
    end
 else
    begin
     Result:=1968;
    end;
end;

Python

SQL Data Check Action - Calculated Parameter example - Python
  Script

import datetime;
if datetime.datetime.today().weekday()==0:
   Result.Value=3917
else:
   Result.Value=3918
  1. Sql Script Action
  2. Sql Data Check Action
  3. Check Connection Action

Video Tutorial


For more technologies supported by our ETL Software see Advanced ETL Processor Versions

Confused? Ask question on our ETL Forum

Posted on June 21, 2026 • 2 min read • 357 words
www.etl-tools.com About Support Pricing Cookies Policy Term Of Use Privacy Policy License