Snowflake
Purpose and Use Case
The zbsync_snowflake module adds the Snowflake Grabber (zbs.grabber.snowflake), which runs a SQL query against a Snowflake data warehouse and returns the result rows to the pipeline. zSYNC currently supports only Snowflake grabbing — there is no Snowflake dumper.
This worker is conceptually the same as the SQL Grabber, but connects to Snowflake specifically rather than a general relational database via SQLAlchemy's generic dialects.
Snowflake Connection
Before using the Snowflake Grabber, create a Snowflake Connection (Connections → Snowflake) with:
| Field | Description |
|---|---|
| Account | Snowflake account identifier. |
| Database | Target database name. |
| Schema | Target schema name. |
| Warehouse | Compute warehouse to run the query on. |
| Username / Password | Login credentials. |
Snowflake Grabber
Configuration
| Field | Description |
|---|---|
| Connection | The Snowflake Connection to query through. |
| SQL | The SELECT statement to run. |
How It Works
- Opens a SQLAlchemy
snowflake://engine using the Connection's account/database/schema/warehouse/credentials. - Executes the configured SQL and fetches all rows.
- Converts each row to a plain dict (decoding any binary column values as UTF-8) before returning it as a pipeline record, ready for a Mapper or Dumper.
Usage and Best Practices
Common Pitfalls
- One query per worker run: the SQL field is a fixed statement — it doesn't currently support the
{where}-style domain substitution used by the SQL Grabber. Build any filtering directly into theSELECTstatement, or use the same variable substitution available to other zSYNC code fields when writing the SQL. - Warehouse must be running/auto-resume enabled: if the configured warehouse is suspended and not set to auto-resume, the query will fail or stall waiting for compute to become available.