Skip to main content

Tasks

Run SQL scripts and Snowflake Python code in your warehouse, then schedule them or add them to orchestrations.

Overview

Tasks let you run custom logic directly in your data warehouse. Each task type has its own editor and runtime, while task testing, states, manual runs, schedules, and orchestrations work consistently across types.

Available task types:

  • SQL Script - Execute SQL statements on any datasource that supports SQL task execution
  • Python Task - Execute Python code on a Snowflake datasource using Snowflake-managed serverless compute

Separate task types that are not yet available:

  • Snowflake dbt - A future Snowflake-specific dbt task type
  • dbt Cloud - A future task type for dbt Cloud jobs
  • AWS Lambda - Invoke Lambda functions
  • Apache Airflow - Trigger Airflow DAGs

dbt Core is available now through transformation projects. Run dbt commands from the project for development, or add the transformation project to an orchestration with ingestion and activation pipelines. The disabled Snowflake dbt and dbt Cloud task cards are separate integrations.

Common use cases:

  • Calculate lead scores after ingesting from Salesforce
  • Aggregate event data into summary tables
  • Run data quality checks and log anomalies
  • Build Snowpark transformations that are easier to express in Python
  • Transform raw data into analytics-ready tables

Prerequisites: An active datasource that supports the selected task type. Review the SQL Script prerequisites or Python Task prerequisites before creating a task.

To access: Navigate to Tasks in the sidebar, then click + Create Task.


Creating a Task

To start:

  1. Navigate to Tasks in the sidebar
  2. Click + Create Task
  3. The task creation flow opens with 3 steps

Step 1: Select Task Type

Select the task type you want to create:

  • SQL Script for SQL statements, transformations, maintenance, or stored procedure calls
  • Python Task for Python code that runs in Snowflake with a Snowpark session

The remaining task types are marked Coming soon and cannot be selected. To run dbt Core today, create a transformation project.


Step 2: Write and Test the Task

Every task must run successfully before you can continue.

  1. Select a datasource from the dropdown
  2. Configure the task using the fields for the selected task type
  3. Write your code in the editor
  4. Click Run to test the task
  5. Verify success in the Result panel

Follow the task-type guide for editor fields, runtime behavior, and troubleshooting:

The Next button is enabled only after the current code and configuration complete successfully. If you change the code, datasource, or type-specific configuration after a successful test, run the task again before continuing.

What happens when you click Run:

  • The task is saved in draft state
  • The code executes against the selected datasource
  • If successful, the task transitions to active state
  • If unsuccessful, the task remains in draft state

Note: If you leave the flow without clicking Next, the task remains saved in its current state. You can edit or delete it from the tasks list later.

To proceed: Click Next after a successful run.


Step 3: Name and Save

Provide a name and optionally add a description.

Task Name (required): Descriptive name for your task, such as "Enrich Leads"

API Name (required): Lowercase identifier for API calls and orchestrations, such as enrich_leads

Description (optional): Add notes about what this task does

To create: Click Save Task.


Running a Task

To run manually:

  1. Navigate to Tasks in the sidebar
  2. Find your task in the tasks list
  3. Click the ••• menu, then select Run Task

The task starts immediately and creates an activity.

You can also add an active task to an orchestration or assign it to a schedule.

To monitor execution: Navigate to Activities. Task runs currently show summary status in the activities list and do not open a separate detail page. Python logs are available in the task editor when you test the code.


Managing Tasks

The tasks list shows all your tasks with columns for NAME, TYPE, DATASOURCE, LAST RUN, and STATE. Click the three-dot menu (•••) on any task row to access management options.

Edit

Modify the code, datasource, task name, or description. Type-specific fields are also available in the editor.

To edit: Click ••• and select Edit.

Run the updated task successfully, then click Save to apply the changes.

Run Task

Manually execute an active task.

To run: Click ••• and select Run Task.

The task starts immediately and creates an activity. Use this option for on-demand runs outside orchestrations and schedules.

Delete

Permanently remove the task.

To delete: Click ••• and select Delete.

Warning:

  • Deletion is permanent and cannot be undone
  • Remove the task from active orchestrations and schedules before deleting it

Task States

Tasks created in the app move between two states:

StateDescriptionHow It Happens
draftTask saved but the current code has not run successfullyCreated before the first successful run or restored after a failed test
activeTask tested and ready for manual, scheduled, or orchestrated runsCurrent code completed successfully

State transitions:

  • Clicking Run in the editor saves the task in draft state before execution
  • Successful execution transitions the task to active state
  • Failed, cancelled, or timed-out execution keeps the task in draft state

Draft tasks remain in the tasks list even if you do not finish the creation flow. You can edit, run, or delete them at any time.


Troubleshooting

For runtime-specific errors, see SQL Script troubleshooting or Python Task troubleshooting.

Next Button Disabled

Problem: Cannot proceed from the editor step.

Solution: Click Run and wait for the current code and configuration to complete successfully. Any change to the datasource, code, or type-specific configuration requires another successful test.

Task Will Not Save

Problem: Cannot save task.

Solution: Ensure the task name is not empty, the API name is unique within the workspace, and the datasource is still active.

Task Used in an Orchestration or Schedule

Problem: You want to delete a task but are unsure where it is used.

Solution: Check Orchestrations and Schedules for references to the task. Remove those references before deleting it.



Support

Need help? Contact us at support@supa-flow.io