Mastering Alteryx Designer for Data Analysts & ETL AutomationLesson 27 of 41
Lesson 27 of 41

In-Database Blending & Aggregation: Join In-DB, Summarize In-DB & Data Stream Out

Overview & Learning Objectives

Pushdown analytics reaches maximum power when performing multi-table relational joins and heavy aggregations directly inside the database. The `Join In-DB` and `Summarize In-DB` tools compile multi-table SQL queries, group by high-cardinality dimensions, and calculate metrics inside the cloud warehouse, allowing the `Data Stream Out` tool to pull only the final aggregated summary into Alteryx Designer.

  • Join massive warehouse tables using Join In-DB specifying join types (Inner, Left, Right, Full Outer).
  • Compute large-scale aggregations using Summarize In-DB inside the host database engine.
  • Bridge the final curated analytical metrics into local Alteryx memory using the Data Stream Out tool.

Industry Standard

Standard: Analytics engineering best practices at Snowflake and EY mandate performing all heavy joins and group-by summarizations In-DB, ensuring the Data Stream Out tool transfers fewer than 100,000 aggregated rows to client memory.

Real-World Example: ScoopCraft Ice Cream National Store-Wise KPI Synthesis

ScoopCraft joins 50 million order facts to 10,000 store dimension rows in Snowflake and streams out only a 20-row regional summary.

In-DB StepAction Executed in SnowflakePushed SQL NodeRecords Handled
Join In-DBJoin `FACT_ORDERS` to `DIM_STORE` on store_idINNER JOIN DIM_STORE ON ...50,000,000 rows blended
Summarize In-DBGroupBy `[Region]`, Sum `[Revenue]`, Count `[Orders]`GROUP BY RegionCondensed 50M rows to 4 rows!
Data Stream OutStream 4 regional summary rows into AlteryxSELECT * FROM (...) queryOnly 4 rows transferred over network!

Configuration & Core Workflow

-- Join In-DB Configuration
Join Fields: Left [store_id] = Right [store_id]
Join Type: Inner Join (or Left Outer / Right Outer / Full Outer)

-- Summarize In-DB Configuration
Field: [Region]      -> Action: GroupBy
Field: [Order_Total] -> Action: Sum
Field: [Order_ID]    -> Action: Count

-- Data Stream Out Configuration
Sort Records: Unchecked (Speed optimization)
Output Format: Standard Alteryx Memory Stream (Green Anchor)

Parameters Breakdown

  • Join In-DB: Blends two In-DB tables on shared keys by appending SQL JOIN syntax to the pushdown query.
  • Summarize In-DB: Aggregates records inside the database, generating `GROUP BY`, `SUM`, `AVG`, `COUNT` clauses.
  • Formula In-DB: Creates new calculated columns using the database engine's native SQL dialect syntax.
  • Data Stream Out: Executes the finalized query in the database and streams the result set into the Alteryx canvas.

Sample Walkthrough (Q&A)

Question: Can you use Join In-DB to join an In-DB Snowflake table to an Excel file sitting on your local laptop?

Formula / Action: Snowflake In-DB (Grey) + Local Excel (Green)

Result: Cannot join directly; they live in different environments!

Explanation: To join them, you must either stream the local Excel file INTO the database using `Data Stream In` (creating a temporary database table), or stream the Snowflake table OUT into memory.

Common Mistakes & Limitations

  • Placing the Data Stream Out tool too early in the pipeline (before filters and joins), which pulls millions of raw records over the network unnecessarily.
  • Using Alteryx-specific formula functions (like `DateTimeDiff`) inside Formula In-DB instead of the native SQL function syntax supported by your database.

Keyboard Shortcuts

ActionWindowsMac
Inspect SQL QueryClick "View Query" in Data Stream Out toolView Query
Quick ExtractConnect Data Stream Out directly to Output Data (.hyper)Data Stream Out

Pro Tips & Modern Alternatives

  • Use `Dynamic Input In-DB` to dynamically modify SQL query strings at runtime based on upstream parameters.
  • Use native dbt (data build tool) models if transformations are strictly SQL transformations scheduled in cloud warehouses.