Insert, Update & Delete in Fabric Warehouse – Full SQL Demo for Beginners
In this tutorial, you'll learn how to use the core DML (Data Manipulation Language) commands — INSERT, UPDATE, and DELETE — in Microsoft Fabric Warehouse. These are the foundation of interacting with structured data in your SQL environment.
📌 What Are DML Commands?
- INSERT: Adds new rows into a table
- UPDATE: Modifies existing rows
- DELETE: Removes rows
Fabric Warehouse fully supports these operations using standard T-SQL syntax.
🏗️ Step 1: Create a Sample Table
CREATE TABLE dbo.Products (
ProductID INT,
ProductName VARCHAR(100),
Category VARCHAR(50),
Price DECIMAL(10, 2),
Stock INT
);
💾 Step 2: Insert Sample Data
INSERT INTO dbo.Products (ProductID, ProductName, Category, Price, Stock) VALUES
(1, 'Laptop', 'Electronics', 1200.00, 10),
(2, 'Smartphone', 'Electronics', 800.00, 25),
(3, 'Desk Chair', 'Furniture', 150.00, 40),
(4, 'Monitor', 'Electronics', 300.00, 15);
Verify Insert:
SELECT * FROM dbo.Products;
✏️ Step 3: Update Data
Increase the price of all Electronics
items by 10%:
UPDATE dbo.Products
SET Price = Price * 1.10
WHERE Category = 'Electronics';
Verify Update:
SELECT * FROM dbo.Products;
❌ Step 4: Delete Data
Delete all products with stock less than 20:
DELETE FROM dbo.Products
WHERE Stock < 20;
Verify Delete:
SELECT * FROM dbo.Products;