ComposableStack.AI CDP
HomeAssessmentAgentLibraryCurriculumHow It WorksSolutionsAbout
← All tasks
Operational taskmodule4· status: no-aep

Run ad-hoc SQL queries against ingested datasets

Connect to the platform's SQL-accessible query layer, enumerate available dataset tables, write standard SQL using XDM dot-notation field paths to retrieve and aggregate event or profile data, and interpret the results for analytical decision-making.

This task produces query results that answer a specific analytical question using data already ingested into the platform — without requiring data export, ETL to a separate analytics store, or proprietary query syntax. The output may be a result set displayed in a terminal or query editor, a downloaded CSV, or a visualization in a connected BI tool. Ad-hoc SQL capability is the primary analytical surface for data engineers and analysts who need to validate ingestion completeness, explore data distributions, or answer business questions directly from platform data.

XDM dot-notation addressing. Unlike relational databases where all columns are flat strings at the table level, XDM datasets store complex object types. Querying them requires dot-notation paths that mirror the XDM schema tree: placecontext.geo.city, commerce.productViews, productListItems.name. The path to any field can be found in the Schema Editor's field-detail panel, which provides a copy-path button. Selecting a complex object without specifying a leaf field (e.g., SELECT placecontext.geo FROM ...) returns the entire object serialized as a string — usually not the intended behavior.

Query timeout and CTAS. The Query Service default timeout is 5 minutes (300 seconds). Queries involving large datasets with complex joins or aggregations may exceed this limit. The recommended pattern for long-running analytical queries is CTAS (Create Table As Select), which executes the query asynchronously and writes results to a named dataset that can be queried later without timeout risk. The new dataset is immediately queryable from any connected BI tool.

BI tool connectivity. Any application that supports the PostgreSQL protocol can connect directly to AEP Query Service using the PSQL connection string displayed in the Query Service UI. This includes Tableau, Microsoft Power BI, Looker, Qlik, and others. The connection string includes a host, port, database name, user, and password; no additional drivers are required beyond the standard PostgreSQL JDBC/ODBC driver.

Parallel viability (high). SQL-based ad-hoc analytics against ingested data is available in every CDW-native CDP: Snowflake, BigQuery, Databricks, Redshift. The XDM dot-notation addressing is AEP-specific; equivalent platforms use flat column names or semi-structured JSON path syntax (e.g., data:event_properties:product_name in BigQuery). The analytical skill — enumerate tables, understand schema structure, write SQL, handle timeouts — transfers directly. Phase 3 will document equivalent Snowflake query patterns.

Side-by-side implementations

Adobe Experience Platform (AEP)

Parallel implementation not yet available.

Snowflake·confidence 85%
SnowflakeAuto-drafted, pending review

Snowflake's query editor (Snowsight) is the direct UI equivalent of AEP's Query Service editor. SQL queries run against Snowflake tables holding the same raw event and profile data; XDM dot-notation addressing is replaced by standard SQL column references and JSON path extraction using `PARSE_JSON(payload):field_name::string` syntax for semi-structured columns. The AEP 5-minute query timeout does not apply — Snowflake has configurable statement timeouts (default 2 hours) set via `STATEMENT_TIMEOUT_IN_SECONDS`. BI tool connectivity uses Snowflake's native JDBC/ODBC drivers or direct connectors available in Power BI, Tableau, and Looker, authenticated with the Snowflake account hostname and credentials rather than a PostgreSQL connection string.

Capability: Reverse-ETL (CDW-to-Destination Sync)

Sources

  • source.docs-snowflake-com.user-guide-ui-snowsight-worksheets
  • source.docs-snowflake-com.sql-reference-functions-semi-structured-parse-json
Hightouch

Parallel implementation not yet available.

Task-level sources

  • technical-training/module4/index.md
  • technical-training/module4/ex1.md
  • technical-training/module4/ex2.md
  • technical-training/module4/ex3.md

How is this implementation?

Sign-in-gated. Tomorrow morning's curriculum-ingestor consumes your feedback: "Inaccurate" queues the task for re-review, "needs update" queues it for a refresh, and "one vendor panel is wrong" re-drafts just that panel.

What kind of feedback?
Sign-in required. Free.