/
New feature GA

Query tags

Query tags is a Databricks compute / bi capability, introduced February 2026.

Custom key-value pairs attached to SQL workloads on Databricks SQL warehouses and Lakehouse//RT compute, set per session or per statement from SQL, the Statement Execution API, dbt, Power BI, Tableau and the drivers, and recorded in system.query.history for grouping, filtering and cost attribution.

  • dbt gets tagged whether it asks or not - every dbt run carries reserved keys such as @@dbt_model_name that you can't override.
  • Power BI stamps its own workspace, report and visual IDs onto queries automatically - but only over the ADBC driver, not ODBC.
  • Genie labels its own homework - queries it generates from benchmarks carry query tags, so you can tell real users from self-tests in query history.

Limitations: Databricks SQL warehouses and Lakehouse//RT compute only - the query_tags column is not populated for other compute. Up to 10 KB of tags per session (extra tags are dropped), at most 20 user-specified tags per query, keys and values up to 128 characters, keys may not contain , : - / = or . and @@ keys are reserved. Tags are stored as plain text and might be replicated globally, so keep secrets and PII out of them.

Open in REbricked →
Category
Compute / BI
Introduced
February 2026
Announced at
Launch blog post (Public Preview)
Also known as
Query Tags, SET QUERY_TAGS, query_tags
Verified
2026-10-20

Sources

Related in Compute / BI