Tutorial: Create a Direct Lake semantic model and Power BI report

Applies to: ✅ SQL analytics endpoint and Warehouse in Microsoft Fabric

In this tutorial, you will create a Direct Lake semantic model and a Power BI report.

Note

This tutorial forms part of an end-to-end scenario. In order to complete this tutorial, you must first complete these tutorials:

  1. Create a workspace
  2. Create a Warehouse
  3. Ingest data into a Warehouse

Create a semantic model

In this task, learn how to create a Direct Lake semantic model based the Wide World Importers warehouse.

  1. Ensure that the workspace you created in the first tutorial is open.

  2. Open the Wide World Importers warehouse.

  3. Select the Reporting tab.

    Screenshot of the Fabric portal, highlighting the Reporting ribbon.

  4. On the Reporting ribbon, select New semantic model.

    Screenshot of the Reporting ribbon, highlighting the New semantic model option.

  5. In the New semantic model window, in the Direct Lake semantic model name box, enter Sales Model.

  6. Expand the dbo schema, expand the Tables folder, and then check the dimension_city and fact_sale tables.

    Screenshot of the New semantic model windows, highlighting the name box, and the selection of the dimension city and fact sale tables.

  7. Select Confirm.

  8. To open the semantic model, return to the workspace landing page, and then select the Sales Model semantic model.

  9. To open the model designer, on the menu, select Open data model.

    Screenshot of the menu, highlighting the Open data model option.

  10. To create a relationship, in the model designer, on the Home ribbon, select Manage relationships.

    Screenshot of the model designer Home ribbon, highlighting the Manage relationships option.

  11. In the Manage relationship window, select + New relationship.

    Screenshot of the New relationship window, highlighting the + New relationship button.

  12. In the New relationship window, complete the following steps to create the relationship:

    1. In the From table dropdown, select the dimension_city table.

    2. In the To table dropdown, select the fact_sale table.

    3. In the Cardinality dropdown, select One to many (1:*).

    4. In the Cross-filter direction dropdown, select Single.

    5. Check the Assume referential integrity box.

      Screenshot of the New relationship window, highlighting the settings.

    6. Select Save.

  13. In the Manage relationship window, select Close.

Create a Power BI report

In this task, learn how to create a Power BI report based on the semantic model you created in the first task.

  1. On the Home ribbon, select New report.

    Screenshot of the model designer Home ribbon, highlighting the New report option.

  2. In the report designer, complete the following steps to create a column chart visual:

    1. In the Data pane, expand the fact_sale table, and then check the Profit field.

    2. In the Data pane, expand the dimension_city table, and then check the SalesTerritory field.

      Screenshot of the column chart visual showing sum of profit by sales territory.

    3. If necessary, resize the column chart visual by dragging the corner of the visual.

    Diagram of the report page layout showing the chart visual placed in the report page.

  3. Select anywhere on the blank canvas to ensure that the column chart visual is no longer selected.

  4. Complete the following steps to create a map visual:

    1. In the Visualizations pane, select the Azure Map visual.

      Screenshot of the Visualizations pane, highlighting the Azure Map visual.

    2. In the Data pane, from inside the dimension_city table, drag the StateProvince fields to the Location well in the Visualizations pane.

      Screenshot of the Data pane, highlighting the drag operation to the Location well.

    3. In the Data pane, from inside the fact_sale table, check the Profit field to add it to the map visual Size well.

    Screenshot of the map visual showing sum of profit by location.

  5. If necessary, reposition and resize the map visual to place it beneath the column chart visual at the bottom-left region of the report page.

    Diagram of the report page layout showing the chart visual placed at the bottom-left region of the report page.

  6. Select anywhere on the blank canvas to ensure that the map visual is no longer selected.

  7. Complete the following steps to create a table visual:

    1. In the Visualizations pane, select the Table visual.

      Screenshot of the Visualizations pane, highlighting the Table visual.

    2. In the Data pane, check the following fields:

      1. SalesTerritory from the dimension_city table
      2. StateProvince from the dimension_city table
      3. Profit from the fact_sale table
      4. TotalExcludingTax from the fact_sale table

    Screenshot of the table visual showing four columns of data.

  8. If necessary, reposition and resize the table visual to place it in an empty region of the report page.

    Diagram of the report page layout showing the table visual placed in the report page.

  9. Verify that the completed design of the report page resembles the following image.

    Screenshot of the completed design of the report page.

  10. To save the report, on the Home ribbon, select File > Save.

  11. In the Save your report window, in the Enter a name for your report box, enter Sales Analysis.

  12. Select Save.

Next step