where a metric view sits · consumers as listed in the Databricks metric views documentation
A minimal example on the samples.tpch.orders sample table:
CREATE OR REPLACE VIEW main.sales.orders_metrics
WITH METRICS
LANGUAGE YAML
AS $$
version: 1.1
source: samples.tpch.orders
fields:
- name: order_month
expr: DATE_TRUNC('MONTH', source.o_orderdate)
- name: order_status
expr: source.o_orderstatus
synonyms: ['status', 'fulfillment status']
measures:
- name: total_revenue
expr: SUM(source.o_totalprice)
display_name: 'Total Revenue'
synonyms: ['revenue', 'sales']
$$
Anyone with SELECT can then query it, wrapping each measure in MEASURE():
SELECT order_month, MEASURE(total_revenue)
FROM main.sales.orders_metrics GROUP BY ALL ORDER BY order_month;
Group by order_status instead and you get revenue by status, with no new view. Display names and synonyms need YAML version 1.1 and Databricks Runtime 17.3 or above (YAML syntax reference).
But isn’t this just a Power BI semantic model?
They work at different layers. A BI semantic model serves one tool’s reports; a metric view lives in Unity Catalog, so one definition reaches AI/BI dashboards, Genie Agents, alerts, JDBC and ODBC clients, Excel and Google Sheets, under the same permissions and lineage as the rest of your data.
The two also work together: Power BI can query a metric view in DirectQuery mode or publish it as a semantic model (Private Preview), Tableau connects through Custom SQL, and Genie Code can import an existing Tableau or Power BI model as a metric view.
Know the trade-offs: metric views don’t support SELECT *, and they can’t be joined directly to other tables at query time, so you wrap the query in a CTE first.
Why does this matter now?
AI agents now ask the questions. When a user asks Genie for “sales by status”, synonyms connect “sales” to the right measure; Databricks notes that synonyms “are automatically imported to help Genie better discover and understand available fields”.
The model grew in 2026. Parameters became generally available on November 13 (Databricks Runtime 18.2 or above), and relationships between metric views entered Beta on October 30, so AI assistants and BI tools can read join paths from Unity Catalog “instead of inferring a join from column names”.
The simple takeaway: define each KPI once in Unity Catalog, query it everywhere, and add synonyms so Genie understands your users. Metric views complement your BI tool; they don’t replace it.
A shared foundation for business metrics
Databricks metric views bring measure definitions into Unity Catalog, giving dashboards, Genie, and AI agents a shared foundation for interpreting business metrics. For teams maintaining several versions of “revenue,” the practical starting point is to agree on the business rules, define the measure, and connect the tools that need it.
As a Databricks Silver Partner, iLink Digital helps enterprises build and govern Databricks data platforms, bringing together data engineering, analytics, AI, and Unity Catalog expertise. That foundation supports the broader goal behind metric views: making business data consistently understood and usable across teams. ilink-digital.com
Evaluating how metric views fit into your existing analytics environment? Talk to iLink’s Databricks experts about your data platform and governance priorities