Power BI Semantic Model Design in Fabric: Direct Lake and Relationships
Introduction
Power BI semantic model design in Fabric starts with the data source, the required freshness and the level at which people analyze results. In this DP-600 lesson you will choose a storage mode, use a star schema, model many-to-many associations and combine actuals and budget at a shared grain.
Learning objectives
- Compare Import, DirectQuery, Dual and Direct Lake storage modes and choose one from business constraints.
- Design a star schema (facts, dimensions, keys, grain) for a semantic model and explain why it beats a flat or snowflaked layout.
- Configure relationships: cardinality, cross-filter direction, active and inactive relationships, bridge tables and many-to-many.
- Explain when the large semantic model storage format is needed and what it changes.
- Build a composite model and understand aggregations, Dual tables and the limitations of mixing storage modes.
1. What a semantic model contains
A Power BI semantic model in Fabric is a tabular model. It defines business logic and relationships independently of the report. Its main parts:
| Part | Role |
|---|---|
| Tables and columns | Imported, DirectQuery, Direct Lake or calculated data |
| Relationships | Define how filters propagate between tables |
| Measures | DAX expressions evaluated in a filter context |
| Hierarchies | Drill paths such as Year > Quarter > Month |
| Roles | Row-level and object-level security |
| Perspectives, translations | Subsets of the model and localized names |
Author models using Power BI Desktop, supported web modeling surfaces, or XMLA tools where write access is available. Power BI projects can store model definitions for source control. Check the authoring path for the chosen storage mode. For example, Direct Lake on SQL is created from the SQL analytics endpoint rather than from Desktop.
2. Choosing a Power BI storage mode
The storage mode of a table decides where the data lives at query time. Evaluate freshness, capacity, data permissions and source support before selecting a mode.
| Mode | Where the data is at query time | Freshness | Strengths | Limits |
|---|---|---|---|---|
| Import | Copied into the model's in-memory columnar store | As fresh as the last refresh | Fast in-memory queries and broad modeling support for compatible connectors | Refresh needed, memory-bound, data duplicated |
| DirectQuery | Queries run at the source when required | Depends on source, caching and refresh of the visual | Avoids a full import of the fact data | Source latency and concurrency matter. Some transformations and calculations are limited |
| Dual | Cached like Import and also queryable live | Cache reflects its last refresh. Source queries depend on the source and visual | Lets a dimension join with both Import and DirectQuery tables efficiently | Only meaningful in composite models |
| Direct Lake | Delta tables in OneLake, columns loaded into memory on demand | Reframing picks up new Delta versions | Import-like speed without a copy or a scheduled import | Needs Delta tables in Fabric, capacity guardrails, some features restricted |
2.1 Import
Import is the default and usually the right answer when the data fits in memory, a refresh schedule is acceptable and you need the richest modeling features. Compression of VertiPaq is typically strong (a column with few distinct values compresses extremely well), so tens of millions of rows often fit in a few hundred megabytes.
Example. A retailer refreshes its sales mart nightly. Users accept yesterday’s data. Benchmark Import against the capacity’s memory and refresh limits, or Direct Lake if the mart is in eligible Delta tables. Measure query latency before committing to a two-second target.
2.2 DirectQuery
Consider DirectQuery when importing the fact is unsuitable or the report needs to query a supported source at report time. Visual and tile caches can show earlier results until refreshed. Measure end-to-end latency and verify SSO if each viewer’s source permissions must apply. Typical constraints:
- Power Query transformations must be foldable to the source.
- Some DAX functions (certain time-intelligence patterns, some iterators) can be slow or unsupported.
- Many concurrent users multiply the load on the source.
2.3 Dual
A Dual table has an Import cache and can participate in DirectQuery when the query needs it. A typical design uses a Dual dimension from the same supported source as a DirectQuery fact. When both tables query that source, the engine can push the join there. A dimension imported only from a different source cannot simply be switched to Dual to remove the cross-source boundary.
2.4 Direct Lake
Direct Lake reads Delta (Parquet) files in OneLake directly into the VertiPaq engine. A refresh of a Direct Lake table performs framing, which updates its reference to the current Delta table version. Automatic updates can reframe it. You can also trigger or schedule framing, for example after the load has finished. This operation does not run a full Import refresh. Columns are then loaded (transcoded) into memory when a query first needs them and evicted under memory pressure.
Compare the two Direct Lake flavors by connection path, fallback behavior and authoring surface.
| Direct Lake on SQL analytics endpoint | Direct Lake on OneLake | |
|---|---|---|
| Connects through | The SQL analytics endpoint of a lakehouse or warehouse | OneLake Delta tables directly |
| DirectQuery fallback | When required and allowed by model settings, for example for a SQL view | Unavailable |
| Mixing with other storage modes | No general composite storage within the Direct Lake on SQL model | Can combine with Import or DirectQuery using supported authoring paths |
Direct Lake suits large Delta tables already produced by pipelines and notebooks, where you want Import-like speed without a duplicate copy and without waiting for an import to finish. It is not the answer when the data is not in OneLake as Delta, for example a SaaS source you have not ingested.
2.5 Worked example: choosing a storage mode
Scenario. A logistics company streams parcel-scan events into an eventhouse and also keeps a 3 TB of raw and curated shipment history as Delta tables in a lakehouse. Dispatchers want a dashboard that is at most one minute behind for the current day, plus analysts want fast history analysis by region and carrier. Headcount for modeling is small and the capacity is F64.
Reasoning, step by step.
- The history lives as Delta tables in OneLake and is large: Direct Lake can read the curated Delta tables without importing the entire history. Check the curated table sizes, row counts and file layout.
- The "last minute" requirement is a streaming need. Use native KQL on the eventhouse for the Real-Time Dashboard. Measure event arrival, processing and dashboard refresh together against the one-minute requirement.
- Analysts need history, region and carrier slicing, DAX measures and security: a semantic model in Direct Lake mode on the shipment tables, with small dimension tables from the same lakehouse.
- Verify the model stays within the capacity guardrails (the maximum rows per table and memory limits depend on the SKU); the SQL flavor can use fallback when allowed, while OneLake must work within its applicable guardrails without fallback.
Solution. Real-Time Dashboard on the eventhouse for the live view, plus a Direct Lake semantic model for historical analysis.
Why the other choices are weaker. A full Import of the curated history adds refresh and memory demands. DirectQuery can fit some requirements, but benchmark the SQL endpoint under the expected query concurrency. Putting the stream into a Direct Lake model does not make it real time, because new Delta versions only become visible after a framing operation.
Exam tip. Use DirectQuery when queries must reach a supported source on demand. Consider Direct Lake for Delta-backed data already in OneLake. Consider Import when refresh latency is acceptable and the model fits its capacity.
3. Star schema for a semantic model
Use Fabric star schema design and fact grain to prepare the tables. The model can then use dimension keys and clear filter paths without rebuilding the business grain in each report.
A star schema has:
- Fact tables: one row per event at a defined grain (for example one row per order line). They hold foreign keys to dimensions and numeric measures (quantity, amount).
- Dimension tables: one row per entity or tracked entity version at the dimension’s declared grain. They hold descriptive attributes used to filter and group.
- Relationships from dimension (one side) to fact (many side), single direction from the dimension to the fact.
Why it works:
| Reason | Effect |
|---|---|
| Filters flow from small dimensions to large facts | Fast scans, simple filter context |
| Dimensions contain all the attributes | Slicers and hierarchies are intuitive |
| Narrow fact tables with integer keys | Better compression, smaller model |
| Predictable ambiguity-free paths | DAX measures return the expected numbers |
Example. A flat export has 40 columns per order line, including customer name, city, product name and category repeated on every row. Importing it as is produces a large model with high-cardinality text columns. Splitting it into FactSales (OrderLineKey, DateKey, CustomerKey, ProductKey, Quantity, NetAmount) and DimCustomer, DimProduct, DimDate reduces memory and gives every slicer one clear home.
3.1 Snowflake versus star
A snowflake normalizes dimensions further (Product > Subcategory > Category as three tables). In a semantic model this lengthens filter paths and complicates the field list. A single product dimension often simplifies filtering and the field list. Retain a separate hierarchy table when the grain or reuse justifies it, and verify the filter paths.
3.2 Date table
For classic time intelligence, use a date dimension with one unique row per day, no gaps, and complete years for the reporting period. Mark the table when required by the model and function, such as when the relationship uses an integer date key. Disable or avoid the automatic date/time hierarchies when you have your own date table, because the hidden tables add size and ambiguity.
3.3 Role-playing dimensions
A fact table often has several dates (OrderDate, ShipDate, DeliveryDate). You create one active relationship and the others inactive, then activate an inactive relationship inside a measure with USERELATIONSHIP. Alternatively duplicate the date table. Only one relationship between a pair of tables can be active. Use separate role-playing date tables when the report needs independent date filters. RLS propagates through active relationships only.
Shipped Amount =
CALCULATE ( [Total Net Amount], USERELATIONSHIP ( FactSales[ShipDateKey], DimDate[DateKey] ) )4. Relationships
A relationship has three properties that matter for the exam.
| Property | Options | Notes |
|---|---|---|
| Cardinality | One-to-many, many-to-one, one-to-one, many-to-many | For a star, the dimension key is unique and filters the fact’s foreign key |
| Cross-filter direction | Single, both | Single is the default and the safest; both enables the filter to travel from many to one |
| Active | Active or inactive | Only one active path between two tables |
4.1 Cross-filter direction
With single direction, selecting a customer filters sales, but selecting sales rows does not filter customers. Both (bidirectional) lets the filter travel the other way. It is tempting but can create ambiguous paths, slower queries and unexpected totals. Prefer single direction and solve specific needs in measures with CROSSFILTER or TREATAS, or with a bridge table designed for the purpose.
4.2 Many-to-many and bridge tables
Real requirements sometimes have many-to-many associations: a customer belongs to several segments, a student takes several courses, a product is sold under several promotions. There are two ways to model them.
Native many-to-many relationship. Power BI lets you define a many-to-many relationship directly between two tables on non-unique columns. This creates a limited relationship. It has no automatic blank member for missing matches and can yield different totals from a regular one-to-many relationship. Use it only when the many-to-many grain is intentional. For a dimension, first check whether its key should be unique.
Bridge table (recommended). A bridge (junction) table contains the unique combinations of the two keys. The model then has two one-to-many relationships from the dimensions to the bridge, and the bridge propagates filters to the fact table.
DimSegment 1 --> * BridgeCustomerSegment * <--> 1 DimCustomer 1 --> * FactSalesFor a segment to filter sales through the bridge, the filter must travel from DimSegment to the bridge, then from the bridge to DimCustomer, which is "many to one" and therefore requires bidirectional filtering on that relationship (or a measure using CROSSFILTER). Limit bidirectional filtering to the relationship that needs it and verify that the model has no ambiguous path.
Worked example: customers in several segments.
Statement. A marketing team tags customers with segments (Gold, Newsletter, At-risk). A customer may have several segments and a segment has many customers. Executives want net revenue by segment and accept that a customer's revenue appears in each of their segments.
Reasoning.
- A single segment column on
DimCustomercannot hold several values, and duplicating customer rows would break the one-row-per-customer grain of the dimension. - Create
BridgeCustomerSegmentwith one row per customer-segment pair. - Relate
DimSegment[SegmentKey]one-to-many to the bridge; relateDimCustomer[CustomerKey]one-to-many to the bridge, with Both selected for the bridge-to-customer relationship;DimCustomerkeeps its single-direction one-to-many toFactSales. - A slicer on
DimSegment[SegmentName]filters the bridge, the bridge filters the customers, the customers filter the sales. - Totals: a grand total across segments counts a multi-segment customer once, while a table broken down by segment counts them once per segment. This is the expected non-additive behavior and should be documented.
Solution. Bridge table with limited bidirectional filtering.
Why not the alternatives. A comma-separated segment column cannot be sliced cleanly. A native many-to-many between DimSegment and FactSales is impossible because the two have no shared column. Bidirectional filtering everywhere would introduce ambiguity.
4.3 Referential integrity and blanks
A regular relationship can expose a virtual blank member for unmatched fact keys. A limited relationship behaves differently and can omit unmatched rows. Fix the key upstream or map it to an explicit Unknown member. For eligible same-source DirectQuery relationships, Assume referential integrity allows inner joins. Enable it only when required foreign keys are non-null and every key has a match.
5. Large semantic model storage format
The large semantic model storage format lets an eligible published model grow beyond the default storage ceiling. It does not increase the capacity's memory or query limits. Microsoft documents the setting for Fabric F, Premium P, Embedded A and PPU, among other eligible configurations.
| Decision | What to check |
|---|---|
| Enable large storage | In the service, open semantic model Settings, turn on Large semantic model storage format and apply |
| Publish and grow the model | The Desktop upload limit remains 10 GB. A supported published model can grow past that on service refresh |
| Refresh a large Import fact | Consider incremental refresh or XMLA partition processing. Check peak memory, especially during the first refresh |
| Optimize XMLA writes | Large storage can improve write performance, including for smaller eligible models |
| Size a Direct Lake model | Review its Delta table and capacity guardrails. Import partition processing does not apply to a Direct Lake table |
Example. An insurer expects its published Import claims model to grow beyond the default 10 GB ceiling. Enable large storage, verify that the expected model size and refresh peak fit the capacity, and use incremental refresh if only recent periods change. Measure the first and subsequent refreshes separately.
6. Aggregations and user-defined aggregation tables
An aggregation table stores pre-summarized data (for example sales by date and product category) in Import mode while the detailed fact stays in DirectQuery. Power BI automatically routes a query to the aggregation when it can answer it, and falls back to the detail table otherwise. You configure the mapping with the "Manage aggregations" dialog. The aggregation table is Import, the dimensions it relates to are typically Dual, and the detail table is DirectQuery. This is the standard pattern for a DirectQuery model that must be fast on summary visuals.
7. Composite models
A composite model combines more than one storage mode or more than one source in a single semantic model. For example, a model can have an Import table for a Budget Excel file, a DirectQuery fact table from a warehouse, and Dual dimensions. A second form of composite model is created when a report author connects to a shared semantic model and adds local tables or measures on top (a "DirectQuery for semantic models" chain).
7.1 Table-level storage modes
In Power BI Desktop's model view you set the storage mode per table. A relationship is limited when it crosses source groups or uses many-to-many cardinality. Storage mode alone does not determine the relationship type. Limited relationships have no table expansion or virtual blank member for unmatched keys, and RELATED cannot fetch a value from the one side across them.
| Relationship between | Type |
|---|---|
| One-to-many within the Import source group | Regular |
| One-to-many within one DirectQuery source group | Regular |
| One-to-many across Import and a DirectQuery source group | Limited |
| Many-to-many cardinality, including within one group | Limited |
7.2 Direct Lake and composite models
- Direct Lake on OneLake supports composite modeling. Import and Direct Lake tables share a source group. DirectQuery tables can be added through supported authoring paths, such as XMLA, subject to connector and model restrictions.
- Direct Lake on SQL does not support general composite storage within that model. A separate downstream model can connect to it and add local tables.
- Calculation groups, field parameters and what-if parameters are special supported objects. General calculated columns and tables that reference Direct Lake data have different restrictions. Microsoft documents a preview for calculated columns in Direct Lake on OneLake in user context and no support for calculated columns on Direct Lake on SQL.
7.3 Worked example: composite model with a budget
Statement. Sales actuals are in Direct Lake on OneLake. Finance has an Excel budget at month and product-category grain. The variance report must use the same filters on actuals and budget.
- Add Budget as an Import table in a supported authoring surface. Keep one row per month and category.
- Use shared Month and Category dimensions, with one unique row per key. Expose MonthKey and CategoryKey on Sales as well as Budget, then relate each dimension one-to-many to both facts.
- Calculate
Variance = [Actual] - [Budget Amount]in visuals at the common grain. A daily or SKU-level filter can affect actuals differently. Avoid showing an unallocated budget at that detail. - If the existing model uses Direct Lake on SQL, ingest Budget into an eligible Delta table at the same grain or use a supported downstream composite model.
Solution. An Import Budget table works with Direct Lake on OneLake. Matching keys and reporting grain make the comparison meaningful.
Common pitfalls
- Choosing DirectQuery "to be safe" for freshness when users only look at yesterday's data: you pay performance for no benefit.
- Applying bidirectional filtering broadly. Keep it scoped to relationships where the design needs it.
- Leaving the automatic date/time tables enabled next to a custom date table.
- Using a many-to-many relationship when a bridge table would give clear semantics.
- Depending on a Direct Lake calculated column without checking the flavor and feature availability. A persisted source column or a measure often has broader support.
Exam tip. When a question describes "ambiguous paths", "unexpected totals" or "slow queries" after relationships were added, look for bidirectional relationships, a snowflake chain or two fact tables joined directly.
Mini case study
Context. Northwind Cycles has a lakehouse with Delta tables fact_orders (210 million rows), dim_customer, dim_product, dim_date, and a table customer_tag (CustomerId, Tag) with several tags per customer. The BI team wants one governed model for all regional reports. Users in Europe must only see European sales. The Marketing team wants revenue by tag. The nightly Power Query-based import of the previous model takes 3 hours.
Questions.
- Which storage mode would you choose and why?
- How do you model the tags?
- How do you give each regional manager their own view?
Solution.
- Direct Lake (on OneLake) because the data already exists as Delta tables in OneLake, the fact table is large, and there is no need for a 3-hour import. The previous Import approach is replaced by framing after the pipeline writes the tables.
- Create
dim_tag(distinct tags) and usecustomer_tagas a bridge betweendim_taganddim_customer, with bidirectional filtering only on the bridge-to-customer relationship. Revenue by tag counts a customer once per tag. - If the requirement is shipment region rather than customer home region, add a sales-region dimension related to the fact. Apply model RLS to that dimension and assign the regional readers to roles. Test with a read-only identity and verify whether OneLake source access is separately available. See Fabric permissions and semantic-model row-level security.
Comment. The solution keeps one star schema, avoids a many-to-many relationship that would be hard to explain, and uses the storage mode that matches the data's location.
Key terms
- Semantic model: tabular model with tables, relationships, measures and security.
- Import / DirectQuery / Dual / Direct Lake: storage modes.
- Framing: Direct Lake refresh that updates the pointers to Delta table versions.
- Star schema: facts joined to denormalized dimensions.
- Grain: what one fact row represents.
- Bridge table: table of key pairs resolving a many-to-many relationship.
- Cross-filter direction: direction in which filters travel across a relationship.
- Large semantic model storage format: setting that lifts the default size ceiling.
- Composite model: model mixing storage modes or sources.
- Limited relationship: a cross-source-group relationship or one with many-to-many cardinality.
Summary checklist
- I can pick Import, DirectQuery, Dual or Direct Lake from freshness, size, source and feature constraints.
- I know the two Direct Lake flavors and their differences in fallback and mixing.
- I can draw a star schema with grain, keys and one-to-many single-direction relationships.
- I can model role-playing dates with one active relationship and
USERELATIONSHIP. - I can resolve many-to-many with a bridge table and limited bidirectional filtering.
- I know when to enable the large semantic model storage format.
- I can describe aggregation tables and Dual dimensions in a composite model.
Official sources
- Study guide for Exam DP-600: https://learn.microsoft.com/en-us/credentials/certifications/resources/study-guides/dp-600 (opens in a new tab)
- Direct Lake overview: https://learn.microsoft.com/en-us/fabric/fundamentals/direct-lake-overview (opens in a new tab)
- How Direct Lake works: https://learn.microsoft.com/en-us/fabric/fundamentals/direct-lake-how-it-works (opens in a new tab)
- Develop Direct Lake semantic models: https://learn.microsoft.com/en-us/fabric/fundamentals/direct-lake-develop (opens in a new tab)
- DirectQuery in Power BI: https://learn.microsoft.com/en-us/power-bi/connect-data/desktop-directquery-about (opens in a new tab)
- Power BI model relationships: https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-relationships-understand (opens in a new tab)
- Composite models and source groups: https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-composite-models (opens in a new tab)
- Large semantic model storage: https://learn.microsoft.com/en-us/fabric/enterprise/powerbi/service-premium-large-models (opens in a new tab)
- Optimization guide for Power BI: https://learn.microsoft.com/en-us/power-bi/guidance/power-bi-optimization (opens in a new tab)
