SnowConvert AI - SSIS

This section provides a comprehensive reference of SSIS elements and components that SnowConvert can convert to dbt and Snowflake. Control Flow elements (tasks and containers) become orchestration logic, while Data Flow components (sources, transformations, destinations) become dbt models.

Control Flow Elements

These SSIS Control Flow tasks and containers are supported:

ElementCategoryConversion TargetNotes
Microsoft.Pipeline (Data Flow Task) (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/data-flow?view=sql-server-ver17)TaskComplete dbt Project-
Microsoft.ExecuteSQLTask (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/execute-sql-task?view=sql-server-ver17)TaskInline SQL or Stored Procedure-
Microsoft.ExecutePackageTask (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/execute-package-task?view=sql-server-ver17)TaskInline EXECUTE TASK or PROCEDURE call-
Microsoft.SendMailTask (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/send-mail-task?view=sql-server-ver17)TaskSYSTEM$SEND_EMAIL with Notification IntegrationSome features not supported; See Send Mail Task section
Microsoft.BulkInsertTask (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/bulk-insert-task?view=sql-server-ver17)TaskCOPY INTO with inline FILE_FORMATRequires stage setup; See Bulk Insert Task section
STOCK:SEQUENCE (Sequence Container) (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/sequence-container?view=sql-server-ver17)ContainerInline sequential execution-
STOCK:FORLOOP (For Loop Container) (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/for-loop-container?view=sql-server-ver17)ContainerSequential executionManual iteration logic required; Check EWI SSC-EWI-SSIS0004 for more information
STOCK:FOREACHLOOP (ForEach Loop Container) (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/foreach-loop-container?view=sql-server-ver17)ContainerLIST/CURSOR patternRequires stage mapping; Check EWI SSC-EWI-SSIS0014 for more information
Event Handlers (https://learn.microsoft.com/en-us/sql/integration-services/integration-services-ssis-event-handlers?view=sql-server-ver17)ContainerNot convertedImplement manually using Snowflake exception handling

Note: Unlisted Control Flow elements generate EWI SSC-EWI-SSIS0004.

Container Conversion Details

SSIS containers (Sequence, For Loop, ForEach, Event Handlers) are converted using an inline approach where container logic is expanded within the parent TASK or procedure rather than creating separate procedures.

Sequence Containers

Sequence containers (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/sequence-container?view=sql-server-ver17) are converted inline within the parent TASK. The container’s boundaries are marked with comments in the generated code, and all tasks within the container execute sequentially in the same TASK scope.

Conversion characteristics:

  • No separate procedure or TASK is created for the container
  • Container boundaries are clearly marked BEGIN … END blocks
  • All tasks execute sequentially within the parent TASK
  • Task execution order based on precedence constraints is maintained
  • Limitation: Only “Success” precedence constraints are fully supported. Conditional execution based on task outcomes (Failure or Completion constraints) is not currently implemented and will require manual post-migration adjustments

Behavioral differences:

  • FDM generated: SSC-FDM-SSIS0003
  • Variable scoping differs from SSIS: Container variables are accessible throughout the entire parent TASK, not just within the container scope

Example:

:force:

-- BEGIN Sequence Container: MySequence
-- Task 1 within sequence
EXECUTE DBT PROJECT public.DataFlow1 ARGS='build --target dev';
-- Task 2 within sequence
EXECUTE DBT PROJECT public.DataFlow2 ARGS='build --target dev';
-- END Sequence Container: MySequence

For Loop Containers

For Loop containers (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/for-loop-container?view=sql-server-ver17) are converted to sequential execution of their contained tasks. However, the loop iteration logic itself requires manual implementation.

Conversion limitations:

  • The container executes once by default (iteration logic not automatically converted)
  • InitExpression, EvalExpression, and AssignExpression require manual conversion
  • An EWI (SSC-EWI-SSIS0004) is generated to indicate manual work is needed

Required manual steps:

  1. Review EvalExpression to understand the loop termination condition
  2. Implement the iteration using Snowflake’s WHILE loop construct
  3. Update AssignExpression logic for proper loop counter management

ForEach Loop Containers

File Enumerator (Supported)

ForEach File Enumerator containers (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/foreach-loop-container?view=sql-server-ver17) are converted to Snowflake stage operations using the LIST command and cursor pattern:

:force:

-- List files from Snowflake stage
LIST @<STAGE_PLACEHOLDER>/FolderPath PATTERN = '.*/file_pattern\.csv';

-- Create cursor for iteration
LET file_cursor CURSOR FOR
   SELECT REGEXP_SUBSTR($1, '[^/]+$') AS FILE_VALUE
   FROM TABLE(RESULT_SCAN(LAST_QUERY_ID()))
   WHERE $1 NOT LIKE '%FolderPath/%/%';

-- Iterate through files
FOR file_row IN file_cursor DO
   User_CurrentFileName := :file_row.FILE_VALUE;
   EXECUTE DBT PROJECT public.My_DataFlow_Project ARGS='build --target dev';
END FOR;

Configuration requirements:

After migration, you’ll need to:

  • Replace <STAGE_PLACEHOLDER> with your actual Snowflake stage name
  • Ensure the folder path is correctly mapped to a Snowflake stage
  • Verify that files are properly staged in Snowflake

An EWI (SSC-EWI-SSIS0014) is generated to remind you of this manual configuration step.

Other Enumerator Types

Other ForEach enumerator types (ForEach Item, ForEach ADO, ForEach NodeList, etc.) aren’t currently supported. SnowConvert generates an EWI (SSC-EWI-SSIS0004) for these cases. Consider implementing the equivalent logic using Snowflake queries or scripting constructs.

Event Handlers

Event handlers (https://learn.microsoft.com/en-us/sql/integration-services/integration-services-ssis-event-handlers?view=sql-server-ver17) (OnError, OnWarning, OnPreExecute, OnPostExecute, etc.) aren’t supported. EWIs are generated. Implement manually using Snowflake exception handling.

Execute SQL Task

Execute SQL Tasks (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/execute-sql-task?view=sql-server-ver17) are converted as inline SQL statements or separate stored procedures, depending on complexity and result set bindings.

Conversion approach:

  • Simple SQL statements: Converted inline within the parent TASK
  • Complex statements with result sets: May be converted to separate stored procedures
  • Result bindings: Handled where possible; unsupported patterns generate EWI SSC-EWI-SSIS0011

Execute Package Task

Execute Package Tasks (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/execute-package-task?view=sql-server-ver17) are handled differently based on package type:

Package TypeConversionNotes
Local (single reference)Inline execution within parent TASKPackage logic expanded inline
Reusable (2+ references or parameters)CALL to stored procedureEnables synchronous execution with parameters; generates FDM SSC-FDM-SSIS0005
ExternalCALL with path resolutionGenerates EWI SSC-EWI-SSIS0008 for manual verification

Asynchronous execution note:

TASK-based Execute Package conversions run asynchronously. For synchronous behavior, packages are converted to stored procedures. See EWI SSC-EWI-SSIS0005.

Send Mail Task

Send Mail Tasks (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/send-mail-task?view=sql-server-ver17) are converted to Snowflake Tasks that use SYSTEM$SEND_EMAIL with a dynamically created Notification Integration.

Key Differences from SSIS

AspectSSISSnowflake
Email ServiceCustom SMTP serverSnowflake’s built-in email service
ConfigurationSMTP Connection ManagerNotification Integration
Sender AddressCustom FROM addressFixed by Snowflake account
CC/BCC SupportFull supportNot supported (merged into recipients)
AttachmentsFile attachments supportedNot supported
HTML BodySupportedPlain text only
PriorityHigh/Normal/LowNot supported

Property Mapping

SSIS PropertySnowflake EquivalentNotes
ToLineALLOWED_RECIPIENTS + recipients parameterDirect mapping
FromLinePrepended to message bodyFDM SSC-FDM-SSIS0008
CCLineAdded to recipients listFDM SSC-FDM-SSIS0009
BCCLineAdded to recipients listFDM SSC-FDM-SSIS0010 (privacy concern)
Subjectsubject parameterDirect mapping
MessageSourcemessage parameterDirect mapping
MessageSourceType (DirectInput)Supported-
MessageSourceType (Variable)SupportedVariable reference converted
MessageSourceType (FileConnection)Not supportedEWI SSC-EWI-SSIS0017
PriorityNot supportedEWI SSC-EWI-SSIS0016
FileAttachmentsNot supportedEWI SSC-EWI-SSIS0015
SMTPConnectionManaged by SnowflakeFDM SSC-FDM-SSIS0007
BodyFormat (HTML)Not supportedEWI SSC-EWI-SSIS0018

Conversion Output Structure

Each Send Mail Task is converted to a Snowflake Task containing:

  1. Notification Integration Creation: Created dynamically via EXECUTE IMMEDIATE
  2. SYSTEM$SEND_EMAIL Call: Sends the email through the integration
:force:

CREATE OR REPLACE TASK public.my_package_send_mail_task
WAREHOUSE=DUMMY_WAREHOUSE
AFTER public.my_package
AS
BEGIN
   -- Step 1: Create Notification Integration dynamically
   BEGIN
      LET my_package_Send_Mail_Task_integration_sql STRING := 'CREATE OR REPLACE NOTIFICATION INTEGRATION my_package_Send_Mail_Task
  TYPE=EMAIL
  ENABLED=TRUE
  ALLOWED_RECIPIENTS=("admin@example.com", "team@example.com")';
      EXECUTE IMMEDIATE :my_package_Send_Mail_Task_integration_sql;
   END;

   -- Step 2: Send the email
   CALL SYSTEM$SEND_EMAIL('my_package_Send_Mail_Task', 'admin@example.com,team@example.com', 'Subject', 'Message body');
END;

Conversion Examples

Basic Email (To, Subject, Body):

:force:

BEGIN
   BEGIN
      LET my_package_Send_Mail_Task_integration_sql STRING := 'CREATE OR REPLACE NOTIFICATION INTEGRATION my_package_Send_Mail_Task
  TYPE=EMAIL
  ENABLED=TRUE
  ALLOWED_RECIPIENTS=("admin@example.com")';
      EXECUTE IMMEDIATE :my_package_Send_Mail_Task_integration_sql;
   END;
   CALL SYSTEM$SEND_EMAIL('my_package_Send_Mail_Task', 'admin@example.com', 'Daily Report', 'The daily report is ready.');
END;

Email with FROM Address:

:force:

BEGIN
   BEGIN
      LET my_package_Send_Mail_Task_integration_sql STRING := 'CREATE OR REPLACE NOTIFICATION INTEGRATION my_package_Send_Mail_Task
  TYPE=EMAIL
  ENABLED=TRUE
  ALLOWED_RECIPIENTS=("noreply@company.com", "admin@example.com")';
      EXECUTE IMMEDIATE :my_package_Send_Mail_Task_integration_sql;
   END;
   --** SSC-FDM-SSIS0008 - SNOWFLAKE'S EMAIL INTEGRATION USES A FIXED SENDER ADDRESS. THE ORIGINAL FROM ADDRESS HAS BEEN PREPENDED TO THE MESSAGE BODY FOR REFERENCE. **
   CALL SYSTEM$SEND_EMAIL('my_package_Send_Mail_Task', 'noreply@company.com,admin@example.com', 'Notification', 'Email sent by: noreply@company.com

Package completed successfully.');
END;

Email with Multiple Features (attachments, priority, CC):

:force:

BEGIN
   BEGIN
      LET my_package_Send_Mail_Task_integration_sql STRING := 'CREATE OR REPLACE NOTIFICATION INTEGRATION my_package_Send_Mail_Task
  TYPE=EMAIL
  ENABLED=TRUE
  ALLOWED_RECIPIENTS=("noreply@company.com", "admin@example.com", "team@example.com")';
      EXECUTE IMMEDIATE :my_package_Send_Mail_Task_integration_sql;
   END;
   !!!RESOLVE EWI!!! /*** SSC-EWI-SSIS0015 - SNOWFLAKE'S SYSTEM$SEND_EMAIL DOES NOT SUPPORT FILE ATTACHMENTS. CONSIDER USING STAGED FILES WITH SHARED LINKS OR ALTERNATIVE DELIVERY METHODS. ***/!!!
   !!!RESOLVE EWI!!! /*** SSC-EWI-SSIS0016 - EMAIL PRIORITY SETTINGS (HIGH/NORMAL/LOW) ARE NOT SUPPORTED BY SYSTEM$SEND_EMAIL AND WILL BE IGNORED. ***/!!!
   --** SSC-FDM-SSIS0008 - SNOWFLAKE'S EMAIL INTEGRATION USES A FIXED SENDER ADDRESS. THE ORIGINAL FROM ADDRESS HAS BEEN PREPENDED TO THE MESSAGE BODY FOR REFERENCE. **
   --** SSC-FDM-SSIS0009 - SNOWFLAKE'S SYSTEM$SEND_EMAIL DOES NOT SUPPORT CC ADDRESSING. ALL CC RECIPIENTS HAVE BEEN ADDED TO THE MAIN RECIPIENTS LIST. **
   CALL SYSTEM$SEND_EMAIL('my_package_Send_Mail_Task', 'noreply@company.com,admin@example.com,team@example.com', 'Monthly Report', 'Email sent by: noreply@company.com

Please review the attached monthly report.');
END;

Prerequisites for Snowflake Email

Before using converted Send Mail Tasks:

  1. Email Notification Integration permissions: Account admin must grant CREATE INTEGRATION ON ACCOUNT to the executing role
  2. Recipient verification: All email addresses in ALLOWED_RECIPIENTS must be verified in Snowflake
  3. Update warehouse name: Replace DUMMY_WAREHOUSE with your actual warehouse name

Workarounds for Unsupported Features

File Attachments:

Upload files to a Snowflake stage and share links instead:

:force:

-- Upload file to stage
PUT file://report.pdf @my_stage;

-- Get shareable link (valid for 1 hour)
LET file_url STRING := GET_PRESIGNED_URL(@my_stage, 'report.pdf', 3600);

-- Include link in email body
CALL SYSTEM$SEND_EMAIL('my_integration', 'admin@example.com', 'Report Available',
  'Download the report from: ' || :file_url);

BCC Privacy:

Send separate emails to maintain recipient privacy:

:force:

-- Send to main recipients
CALL SYSTEM$SEND_EMAIL('my_integration', 'admin@example.com', 'Subject', 'Message');

-- Send separately to BCC recipients
CALL SYSTEM$SEND_EMAIL('my_integration', 'audit@example.com', 'Subject', 'Message');

Bulk Insert Task

Bulk Insert Tasks (https://learn.microsoft.com/en-us/sql/integration-services/control-flow/bulk-insert-task?view=sql-server-ver17) are converted to Snowflake Tasks that use COPY INTO with an inline FILE_FORMAT. The conversion generates a stage placeholder that you must configure before execution.

Key Differences from SSIS

AspectSSISSnowflake
Data SourceFile system path or UNC pathSnowflake Stage (internal or external)
File FormatFormat file (.fmt/.xml) or inline optionsFILE_FORMAT object or inline options
Native FormatNative/WideNative supportedNot supported (CSV, JSON, Parquet, etc.)
Row FilteringFirstRow/LastRow optionsNot directly supported
Batch ControlBatchSize configurableAutomatic management
Error HandlingMaximumErrors countON_ERROR behavior
TriggersFireTriggers optionNot supported (use Streams/Tasks)
Table LockingTableLock optionNot needed (MVCC)

Property Mapping

SSIS PropertySnowflake EquivalentNotes
DestinationTableNameCOPY INTO tableSquare brackets [] removed
DataFileType (Char)TYPE = 'CSV'Direct mapping
DataFileType (Native)Not supportedEWI SSC-EWI-SSIS0020
FieldTerminatorFIELD_DELIMITERParsed from SSIS format
RowTerminatorRECORD_DELIMITERParsed from SSIS format
FirstRowSKIP_HEADERValue - 1
LastRowNot supportedEWI SSC-EWI-SSIS0021
MaximumErrorsON_ERRORFDM SSC-FDM-SSIS0011
KeepNulls=TrueNULL_IF = ()Empty tuple
KeepNulls=FalseNULL_IF = ('', 'NULL', 'null')Default behavior
KeepIdentity=FalseFDM generatedFDM SSC-FDM-SSIS0017
TableLock=TrueNot neededFDM SSC-FDM-SSIS0014
FireTriggers=TrueNot supportedEWI SSC-EWI-SSIS0022
FormatFileNot supportedEWI SSC-EWI-SSIS0023
CheckConstraints=TrueAlways enforcedFDM SSC-FDM-SSIS0016
BatchSizeAutomaticFDM SSC-FDM-SSIS0012
SortedDataNot availableFDM SSC-FDM-SSIS0015

Terminator Parsing

SSIS uses specific tokens for field and row terminators. These are converted to Snowflake escape sequences:

SSIS FormatSnowflake Output
{CR}{LF}\r\n
{CR}\r
{LF}\n
{TAB}\t
Tab\t
Comma {,},
Semicolon {;};
Vertical Bar {|}|

Conversion Output Structure

Each Bulk Insert Task is converted to a Snowflake Task containing a COPY INTO statement with an inline FILE_FORMAT:

:force:

CREATE OR REPLACE TASK public.package_bulk_insert_task
WAREHOUSE=DUMMY_WAREHOUSE
AFTER public.package
AS
BEGIN
   ---- Start block 'Package\BulkInsertTask'
   !!!RESOLVE EWI!!! /*** SSC-EWI-SSIS0024 - THE STAGE AND FILE UPLOAD ARE NOT INCLUDED IN THE TRANSLATION. CREATE A SNOWFLAKE STAGE AND UPLOAD THE SOURCE FILE BEFORE EXECUTING THE COPY INTO STATEMENT. REPLACE {STAGE_PLACEHOLDER} WITH YOUR STAGE NAME. ***/!!!
   COPY INTO target_table
   FROM '@{STAGE_PLACEHOLDER}'
   PATTERN = '.*data_file.*'
   FILE_FORMAT = (TYPE = 'CSV', FIELD_DELIMITER = ',', RECORD_DELIMITER = '\r\n', SKIP_HEADER = 1, NULL_IF = ('', 'NULL', 'null'), ERROR_ON_COLUMN_COUNT_MISMATCH = FALSE)
   ON_ERROR = CONTINUE;
   ---- End block 'Package\BulkInsertTask'
END;

Conversion Examples

Basic Bulk Insert (CSV with default options):

:force:

CREATE OR REPLACE TASK public.package_load_customers
WAREHOUSE=DUMMY_WAREHOUSE
AS
BEGIN
   !!!RESOLVE EWI!!! /*** SSC-EWI-SSIS0024 - THE STAGE AND FILE UPLOAD ARE NOT INCLUDED IN THE TRANSLATION. CREATE A SNOWFLAKE STAGE AND UPLOAD THE SOURCE FILE BEFORE EXECUTING THE COPY INTO STATEMENT. REPLACE {STAGE_PLACEHOLDER} WITH YOUR STAGE NAME. ***/!!!
   COPY INTO Customers
   FROM '@{STAGE_PLACEHOLDER}'
   PATTERN = '.*customers\.csv.*'
   FILE_FORMAT = (TYPE = 'CSV', FIELD_DELIMITER = ',', RECORD_DELIMITER = '\r\n', SKIP_HEADER = 0, NULL_IF = ('', 'NULL', 'null'), ERROR_ON_COLUMN_COUNT_MISMATCH = FALSE)
   ON_ERROR = CONTINUE;
END;

Bulk Insert with Tab Delimiter and Header Skip:

:force:

CREATE OR REPLACE TASK public.package_load_products
WAREHOUSE=DUMMY_WAREHOUSE
AS
BEGIN
   !!!RESOLVE EWI!!! /*** SSC-EWI-SSIS0024 - THE STAGE AND FILE UPLOAD ARE NOT INCLUDED IN THE TRANSLATION. CREATE A SNOWFLAKE STAGE AND UPLOAD THE SOURCE FILE BEFORE EXECUTING THE COPY INTO STATEMENT. REPLACE {STAGE_PLACEHOLDER} WITH YOUR STAGE NAME. ***/!!!
   COPY INTO Products
   FROM '@{STAGE_PLACEHOLDER}'
   PATTERN = '.*products\.txt.*'
   FILE_FORMAT = (TYPE = 'CSV', FIELD_DELIMITER = '\t', RECORD_DELIMITER = '\n', SKIP_HEADER = 1, NULL_IF = ('', 'NULL', 'null'), ERROR_ON_COLUMN_COUNT_MISMATCH = FALSE)
   ON_ERROR = SKIP_FILE_10;
END;

Bulk Insert with Multiple EWIs (Native format, LastRow, FireTriggers):

:force:

CREATE OR REPLACE TASK public.package_load_orders
WAREHOUSE=DUMMY_WAREHOUSE
AS
BEGIN
   !!!RESOLVE EWI!!! /*** SSC-EWI-SSIS0020 - SSIS BULKINSERTTASK NATIVE OR WIDENATIVE DATA FILE TYPE IS NOT SUPPORTED IN SNOWFLAKE. EXPORT SOURCE DATA TO CSV FORMAT BEFORE MIGRATION. ***/!!!
   !!!RESOLVE EWI!!! /*** SSC-EWI-SSIS0021 - SSIS BULKINSERTTASK LASTROW OPTION IS NOT SUPPORTED IN SNOWFLAKE. USE TEMPORARY TABLE WITH ROW_NUMBER AND LIMIT/OFFSET TO SELECT SPECIFIC ROW RANGE. ***/!!!
   !!!RESOLVE EWI!!! /*** SSC-EWI-SSIS0022 - SSIS BULKINSERTTASK FIRETRIGGERS OPTION IS NOT SUPPORTED IN SNOWFLAKE. CONSIDER USING SNOWFLAKE STREAMS AND TASKS TO IMPLEMENT TRIGGER-LIKE BEHAVIOR. ***/!!!
   !!!RESOLVE EWI!!! /*** SSC-EWI-SSIS0024 - THE STAGE AND FILE UPLOAD ARE NOT INCLUDED IN THE TRANSLATION. CREATE A SNOWFLAKE STAGE AND UPLOAD THE SOURCE FILE BEFORE EXECUTING THE COPY INTO STATEMENT. REPLACE {STAGE_PLACEHOLDER} WITH YOUR STAGE NAME. ***/!!!
   COPY INTO Orders
   FROM '@{STAGE_PLACEHOLDER}'
   PATTERN = '.*orders\.dat.*'
   FILE_FORMAT = (TYPE = 'CSV', FIELD_DELIMITER = ',', RECORD_DELIMITER = '\r\n', SKIP_HEADER = 0, NULL_IF = ('', 'NULL', 'null'), ERROR_ON_COLUMN_COUNT_MISMATCH = FALSE)
   ON_ERROR = CONTINUE;
END;

Stage Setup (Required)

Before executing converted Bulk Insert Tasks, you must:

  1. Create a Snowflake stage:
:force:

CREATE OR REPLACE STAGE my_bulk_stage;
  1. Upload files using SnowSQL CLI:
:force:

PUT file:///path/to/data.csv @my_bulk_stage AUTO_COMPRESS = FALSE;
  1. Replace the stage placeholder in generated code:
:force:

-- Change this:
FROM '@{STAGE_PLACEHOLDER}'

-- To this:
FROM '@my_bulk_stage'
  1. Verify files are staged:
:force:

LIST @my_bulk_stage;

Workarounds for Unsupported Features

Native Data Format:

Export SQL Server data to CSV format before migration. The native binary format is not supported by Snowflake.

LastRow Filtering:

Load to staging table and filter:

:force:

-- Load all data
COPY INTO staging_table FROM '@my_stage' ...;

-- Insert only rows up to LastRow value
INSERT INTO target_table
SELECT * FROM (
  SELECT *, ROW_NUMBER() OVER (ORDER BY 1) AS rn
  FROM staging_table
) WHERE rn <= 1000;  -- Original LastRow value

FireTriggers (Trigger-like Behavior):

Use Snowflake Streams and Tasks:

:force:

-- Create stream to capture inserts
CREATE OR REPLACE STREAM target_stream ON TABLE target_table;

-- Create task to process inserts (trigger logic)
CREATE OR REPLACE TASK process_inserts
  WAREHOUSE = my_warehouse
  SCHEDULE = '1 minute'
  WHEN SYSTEM$STREAM_HAS_DATA('target_stream')
AS
  INSERT INTO audit_table
  SELECT *, CURRENT_TIMESTAMP()
  FROM target_stream
  WHERE METADATA$ACTION = 'INSERT';

dbt Project Execution

Within the orchestration code, Data Flow Tasks are executed using Snowflake’s EXECUTE DBT PROJECT command:

:force:

EXECUTE DBT PROJECT schema.project_name ARGS='build --target dev'

Important requirements:

  • The project_name must match the name you used when deploying the dbt project (via CREATE DBT PROJECT or Snowflake Workspace deployment)
  • Arguments passed are standard dbt CLI arguments (like build, run, test)
  • Each execution runs the entire dbt project with all models in dependency order

Deployment:

Before executing dbt projects in orchestration, deploy them using:

  • Snowflake CLI: snow dbt deploy --schema schema_name --database database_name --force package_name
  • Snowflake Workspace: Upload and deploy via UI

For complete deployment instructions, see the user guide.

Data Flow Components

These SSIS Data Flow sources, transformations, and destinations are supported:

ComponentCategorydbt MappingModel NamingNotes
Source Components
Microsoft.OLEDBSource (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/ole-db-source?view=sql-server-ver17)SourceStaging Modelstg_raw__{component_name}-
Microsoft.FlatFileSource (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/flat-file-source?view=sql-server-ver17)SourceStaging Modelstg_raw__{component_name}-
Transformation Components
Microsoft.DerivedColumn (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/transformations/derived-column-transformation?view=sql-server-ver17)TransformationIntermediate Model (SELECT with expressions)int_{component_name}-
Microsoft.DataConvert (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/transformations/data-conversion-transformation?view=sql-server-ver17)TransformationIntermediate Model (CAST expressions)int_{component_name}-
Microsoft.Lookup (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/transformations/lookup-transformation?view=sql-server-ver17)TransformationIntermediate Model (LEFT JOIN)int_{component_name}Might present functional differences for ORDER BY requirements. Check FDM SSC-FDM-SSIS0001 for more information
Microsoft.UnionAll (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/transformations/union-all-transformation?view=sql-server-ver17)TransformationIntermediate Model (UNION ALL)int_{component_name}-
Microsoft.Merge (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/transformations/merge-transformation?view=sql-server-ver17)TransformationIntermediate Model (UNION ALL)int_{component_name}Might present functional differences for sorted output. Check FDM SSC-FDM-SSIS0002 for more information
Microsoft.MergeJoin (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/transformations/merge-join-transformation?view=sql-server-ver17)TransformationIntermediate Model (JOIN)int_{component_name}Might present functional differences for ORDER BY requirements. Check FDM SSC-FDM-SSIS0004 for more information
Microsoft.ConditionalSplit (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/transformations/conditional-split-transformation?view=sql-server-ver17)TransformationIntermediate Model (Router pattern with CTEs)int_{component_name}-
Microsoft.Multicast (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/transformations/multicast-transformation?view=sql-server-ver17)TransformationIntermediate Model (SELECT pass-through)int_{component_name}-
Microsoft.RowCount (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/transformations/row-count-transformation?view=sql-server-ver17)TransformationIntermediate Model with macroint_{component_name}Uses m_update_row_count_variable macro
Destination Components
Microsoft.OLEDBDestination (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/ole-db-destination?view=sql-server-ver17)DestinationMart Model (table){target_table_name}-
Microsoft.FlatFileDestination (https://learn.microsoft.com/en-us/sql/integration-services/data-flow/flat-file-destination?view=sql-server-ver17)DestinationMart Model (table){target_table_name}-

Note: Unlisted Data Flow components generate EWI SSC-EWI-SSIS0001.