Skip to content
TREN

Semantic Views in Fabric Preview: Building Your First Semantic View with YAML and DAX (Hands-On Guide)

Semantic views entered public preview at Ignite 2026. Describing tables and relationships in YAML, writing DAX metrics, publishing, and connecting reports and agents to the generated read-only Direct Lake model; plus permissions and preview limits.

Semantic Views in Fabric Preview: Building Your First Semantic View with YAML and DAX (Hands-On Guide)
In this post 14
  1. In short
  2. What a semantic view is, and what it isn’t
  3. Prerequisites
  4. Step 1: Create the view
  5. Step 2: Describe the tables and relationships
  6. Step 3: Write the metrics in DAX
  7. Step 4: Publish and validate
  8. Step 5: Connect a report and an agent
  9. Permissions and security
  10. Reusing a definition across lakehouses
  11. The preview’s limits
  12. Semantic view or semantic model?
  13. My take
  14. Sources

Author: @atilayberber

Semantic Views in Fabric Preview: Building Your First Semantic View with YAML and DAX (Hands-On Guide)
Cheat sheet: Semantic Views in Fabric Preview: Building Your First Semantic View with YAML and DAX (Hands-On Guide)

At the end of October I wrote a debate post about OneLake semantic views and Apache Ossie. Back then all we had was a sneak peek, and the question was “what happens when business definitions leave the Power BI model?” At Ignite 2026 semantic views entered public preview, and Microsoft Learn published a step-by-step tutorial. Time to stop debating and get our hands dirty.

In this post we build a first semantic view in a lakehouse: we describe tables and relationships in YAML, write the metrics in DAX, publish, and connect to the generated model. Then we look at the preview’s limits, at permissions, and at the question “when do I pick a semantic view, and when a classic semantic model?”

In short

  • A semantic view holds definitions, not data: datasets, relationships, business metrics and their descriptions. It lives in the lakehouse, right next to the data, as open YAML.
  • The format is built on Apache Ossie (incubating). In the preview, metrics must be written in DAX.
  • Publishing creates a read-only, managed Direct Lake on OneLake semantic model. Reports and data agents connect to that model; the YAML files stay the source of truth.
  • The preview works only in lakehouses, with single-column relationships, and in workspaces without CI/CD connections.
  • There’s no separate meter: the files use OneLake storage and queries use the existing Direct Lake query meters.

What a semantic view is, and what it isn’t

Figure 1: A semantic view holds definitions, not data
Figure 1: A semantic view holds definitions, not data

Learn is clear about this: a semantic view isn’t a standalone Fabric item or a query engine. It’s a lightweight, reusable definition stored in the lakehouse. Microsoft doesn’t position it as a new version of the semantic model or a replacement either; the two complement each other.

The flow looks like this:

  1. The Delta tables in the lakehouse (for example dbo.factsales) stay where they are.
  2. You write YAML files in the Context/Semantic Views/<view-name>/ folder.
  3. When you Publish, Fabric validates and merges the files and writes a read-only TMDL output under SystemContext.
  4. That TMDL becomes a Direct Lake on OneLake semantic model with the same name as the view.
  5. A Power BI report connects to it with a live connection, and a data agent adds it as a data source.

If you want a refresher on how Direct Lake works, see the Direct Lake post; the generated model is queried by the same rules.

Prerequisites

  • A Fabric-enabled workspace where you have the Contributor role or higher.
  • A lakehouse with schemas enabled, on which you have Write permission.
  • A workspace that is not connected to a deployment pipeline, Git or a Power Platform solution, and that does not have workspace-level private links enabled. If any of those apply, publishing isn’t allowed.

I’d run the first test in a lakehouse created just for it, not an existing one. The Learn tutorial says the same and shares sample CSV files in the fabric-samples repository.

Step 1: Create the view

Open the lakehouse, select New semantic view on the ribbon, give it a name (for example sales) and select Create. Fabric creates the Context/Semantic Views/sales/ folder with a starter file full of commented examples. The folder name matters: the names of the view and of the generated model come from it. The name field inside the YAML is required but unused.

Step 2: Describe the tables and relationships

Figure 2: Two files, one view
Figure 2: Two files, one view

Rename the starter file to schema.yaml and write a structure like this:

version: 0.2.0.dev0
name: sales
description: Sales metrics by region and category.
datasets:
  - name: sales
    source: dbo.factsales
    description: One row per sales transaction line.
  - name: stores
    source: dbo.dimstore
    description: One row per store, including its region.
  - name: products
    source: dbo.dimproducts
    description: One row per product, including its category.
relationships:
  - name: sales_to_stores
    from: sales
    to: stores
    from_columns: [StoreId]
    to_columns: [StoreId]
  - name: sales_to_products
    from: sales
    to: products
    from_columns: [ProductId]
    to_columns: [ProductId]

Two details: source points to the real table in the lakehouse, while name is the name you use inside the view. In the preview, relationships support a single column on each side; if you have a composite key, produce a single key column in the table first. Saving only writes the file; validation happens at publish time.

Step 3: Write the metrics in DAX

Add a second file named metrics.yaml to the same folder. Publishing merges both files into one view:

version: 0.2.0.dev0
name: sales
metrics:
  - name: Total Revenue
    description: Total sales revenue in US dollars.
    expression:
      dialects:
        - dialect: DAX
          expression: "SUM('sales'[RevenueUSD])"
  - name: Sale Count
    description: Number of distinct sales transactions.
    expression:
      dialects:
        - dialect: DAX
          expression: "DISTINCTCOUNT('sales'[SaleId])"
  - name: Revenue per Sale
    description: Total revenue divided by the number of sales.
    expression:
      dialects:
        - dialect: DAX
          expression: "DIVIDE([Total Revenue], [Sale Count])"

The most common mistake: inside DAX you reference a table by its YAML name ('sales'), not by dbo.factsales. A metric can also use another metric, as the third example shows. According to the Ignite announcement, time intelligence such as year-over-year and rolling-period logic can be written as DAX metrics too.

Step 4: Publish and validate

Figure 3: Folders: what lives where?
Figure 3: Folders: what lives where?

In the Explorer, right-click the sales folder under Context > Semantic Views and select Publish. The first publish can take a while; wait for the result. If it fails, Fabric tells you what’s wrong in which file; fix it and publish again. Read the warnings as well.

When publishing finishes, you’ll see the generated TMDL under SystemContext > Semantic Views > sales. Open in model view opens the model for inspection, not editing. Validate in DQV opens DAX query view, where you test the metrics:

EVALUATE
SUMMARIZECOLUMNS(
    'stores'[Region],
    "Revenue", [Total Revenue],
    "Sales", [Sale Count],
    "Per sale", [Revenue per Sale]
)
ORDER BY 'stores'[Region]

If the results don’t match what you expect, check loaded row counts, numeric column types and the relationship columns first.

Step 5: Connect a report and an agent

The generated model carries the view’s name in the workspace (sales). In Power BI Desktop you can Connect to it from the OneLake catalog with a live connection and build a report. In a data agent, select Add data source and pick the same model. To change a metric, you edit the YAML and publish again; you don’t touch the model directly.

Permissions and security

Figure 4: Permissions come from the lakehouse
Figure 4: Permissions come from the lakehouse

The generated model inherits its permissions from the lakehouse:

Lakehouse permissionGenerated model permission
ReadRead and Build
WriteWrite

That has practical consequences:

  • The model stays read-only. Power BI Desktop offers Connect but not Edit (remote modeling).
  • Access through the XMLA endpoint and creating ontologies from the generated model aren’t supported.
  • The Context folder doesn’t support OneLake security; the generated model does.
  • In a view that includes OLS-restricted tables or columns, users who can read SystemContext can see metadata about those objects. The data itself isn’t exposed, but keep it in mind where even column names are sensitive.

Reusing a definition across lakehouses

A view can’t reference tables in another lakehouse directly. To reuse a centrally maintained definition, create OneLake shortcuts to the view folders in the consuming lakehouse and publish the view there. Every referenced table and column must resolve in the consuming lakehouse. When the shared definition changes, republish the consuming views; their models don’t update on their own.

The preview’s limits

Figure 5: The preview's limits
Figure 5: The preview's limits
  • Lakehouses only: you can’t create views in a warehouse or other sources.
  • DAX metrics: published metrics require DAX.
  • Single-column relationships.
  • No CI/CD: you can’t publish in workspaces connected to deployment pipelines, Git or Power Platform solutions.
  • Private links: publishing isn’t allowed in workspaces with workspace-level private links, and you can’t enable them later in a workspace that contains the generated model.
  • No locking: publish doesn’t lock files; if two people publish at the same time, the last write wins.
  • Renaming and deleting: renaming the view folder or its model can stop later publishes from updating the original model. Deleting the model and republishing doesn’t restore old connections. Deleting the lakehouse deletes its generated models.
  • Name conflicts: publishing fails if the workspace already has another item with the same name.
  • .yaml only: other files in the folder aren’t published, and there are size and file-count limits.

Semantic view or semantic model?

SituationChoice
Keep definitions next to the data, tool-independent, reused across lakehousesSemantic view
Multiple sources, Import or mixed storage modes, calculated tablesSemantic model
Work with Tabular Editor, XMLA and existing modeling toolsSemantic model
Enterprise model managed with Git and deployment pipelinesSemantic model, for now
Small, lakehouse-centric areas where agents and reports share the same metricsPilot with a semantic view

My take

In October I asked, “is DAX losing its monopoly?” After building the preview, my answer hasn’t changed, but it’s sharper: DAX isn’t losing, it’s changing address. The metric language is still DAX; what changes is that the definition no longer lives inside a .pbix but next to the data, in an open file. For me that’s the strongest part: seeing a metric as a YAML line in Git (once CI/CD support arrives) and having the same definition reach both the report and the agent.

But don’t move your production enterprise model to it today. There’s no CI/CD support, the model is read-only, and relationships are single-column. The right start is a pilot in a small, lakehouse-centric subject area, for example an operations dashboard or the 5–10 metrics a data agent relies on. If you’re curious about giving agents business context, the Fabric IQ ontology post covers the next layer up.

Which metrics would you put in your first semantic view? Let me know in the comments or on LinkedIn.

Sources

If you found it useful, share it on LinkedIn and ask your questions there.

Read next Same topic · Microsoft Fabric · 13 minFabric Data Warehouse at Ignite 2026: Performance, MCP, QUALIFY and Warehouse Clones for Agent-Paced Analytics

Leave a comment

Your email address will not be published. Required fields are marked *

STAY IN THE LOOP

New guides, sorted by topic in a single email.

Every Monday, the week's new posts arrive grouped by topic. No new posts, no email.

Nothing is sent until you click the link in the confirmation email. Unsubscribe anytime with one click.