Microsoft Fabric (Part 1)

Neil Haddley โ€ข November 27, 2026

I created a Lakehouse in Microsoft Fabric, uploaded a sales CSV, turned it into a Delta table, queried it with the SQL analytics endpoint, and charted it with PySpark in a notebook.

AzureSQLmicrosoft-fabriclakehouseonelakepysparkdelta-lake

In this post I follow one file through Microsoft Fabric. I put it in a Lakehouse, turned it into a table, and queried that same table two ways: with SQL and with Python.

I used a small file of 200 sales orders from January to June 2026. I generated it myself, and you can download sales.csv to follow along.

Start a workspace on a Fabric trial

I opened the Fabric home page and signed in.

The Fabric home page

The Fabric home page

My tenant had no Fabric capacity at first, so the Fabric workspace type was greyed out when I tried to create a workspace. I started the 60-day Fabric trial from my profile menu. After that, the header read "Trial activated: 66 days left", and a new workspace type called Fabric Trial appeared.

I clicked New workspace and named it Sales Lakehouse Tutorial.

I named the workspace

I named the workspace

I chose Fabric Trial as the workspace type

I chose Fabric Trial as the workspace type

The new workspace was empty

The new workspace was empty

Create the Lakehouse

In the workspace I clicked New item, typed Lakehouse into the filter box, and chose Lakehouse.

I filtered the item list for Lakehouse

I filtered the item list for Lakehouse

I named it SalesLakehouse and left Lakehouse schemas ticked, so my tables would go into a dbo schema.

I named the Lakehouse

I named the Lakehouse

Fabric created the Lakehouse and, at the same time, a SQL analytics endpoint for it. The Explorer shows two areas: Tables for Delta tables and Files for anything else.

The empty Lakehouse, with Tables and Files

The empty Lakehouse, with Tables and Files

Upload the CSV

I clicked Upload files, chose sales.csv, and clicked Upload. The file landed in Files, because a CSV is a file, not a table yet.

The upload finished: sales.csv, 10 KB

The upload finished: sales.csv, 10 KB

Turn the file into a Delta table

I right-clicked sales.csv, chose Load to Tables, and then New table.

I chose Load to Tables, then New table

I chose Load to Tables, then New table

The defaults were what I wanted: schema dbo, table name sales, and the first row used as column names. I clicked Load.

The Load file to new table dialog

The Load file to new table dialog

A few moments later the sales table appeared under dbo. The data preview showed all 200 rows and 8 columns, and Fabric had worked out the types: OrderDate is a date, and the quantities and prices are numbers.

The sales table: 200 rows, 8 columns

The sales table: 200 rows, 8 columns

Query it with SQL

From Analyze data with, I chose SQL analytics endpoint.

The Analyze data with menu

The Analyze data with menu

The SQL analytics endpoint, ready for a query

The SQL analytics endpoint, ready for a query

I clicked New SQL query and ran this:

SQL
1SELECT Category, COUNT(*) AS Orders, SUM(Total) AS Revenue
2FROM dbo.sales
3GROUP BY Category
4ORDER BY Revenue DESC;
Bikes brought in far more revenue than the other three categories

Bikes brought in far more revenue than the other three categories

CategoryOrdersRevenue
Bikes2669,223
Safety486,660
Accessories935,852
Clothing332,064

I checked these figures against the CSV with a short Python script on my Mac, and they matched exactly.

Chart it in a notebook

I went back to the Lakehouse and chose Analyze data with, then Notebook, then New notebook. The notebook opened with SalesLakehouse already attached.

I created a new notebook from the Lakehouse

I created a new notebook from the Lakehouse

I replaced the placeholder comments with this PySpark code, which reads the same dbo.sales table, adds a month column, and draws stacked bars:

PYTHON
1import matplotlib.pyplot as plt
2from pyspark.sql import functions as F
3df = spark.read.table("dbo.sales").withColumn("Month", F.date_format("OrderDate", "yyyy-MM"))
4pdf = df.groupBy("Month", "Category").agg(F.sum("Total").alias("Revenue")).toPandas()
5pivot = pdf.pivot(index="Month", columns="Category", values="Revenue").fillna(0).sort_index()
6pivot.plot(kind="bar", stacked=True, figsize=(9, 5), title="Monthly revenue by category")
7plt.ylabel("Revenue")
8plt.tight_layout()
9plt.show()
The code in the first cell

The code in the first cell

The chart appeared under the cell. Bikes dominate every month, and the revenue falls from January to April, rises in May, and falls again in June.

Monthly revenue by category, drawn from the same table that the SQL query used

Monthly revenue by category, drawn from the same table that the SQL query used

Where the old SQL Server tools went

I came to Fabric knowing SSAS, SSIS and SSRS, so I looked up where each one lives now. I read the Microsoft Learn pages for this. I did not try any of the three below.