Azure SQL: Your Database in the Cloud
Azure SQL is Microsoft's family of cloud relational databases. Learn the three options — Azure SQL Database, Managed Instance, and SQL Server on VMs — and when to use each.
The Azure SQL family
Azure SQL gives you three ways to run SQL Server in the cloud — from fully managed to fully controlled.
Think of it like accommodation: Azure SQL Database is a hotel (everything managed for you), Managed Instance is a serviced apartment (more space and flexibility, but still maintained), and SQL Server on VMs is renting a whole house (you control everything, but you maintain it too).
The three options
Azure SQL Database
The fully managed option. Microsoft handles patching, backups, high availability, and scaling. You just create databases and build your app.
Best for: New cloud-native applications, SaaS products, web apps.
Jake’s choice: CloudPulse uses Azure SQL Database for their production app — they don’t want to manage servers, and the built-in high availability keeps customers happy.
Key features:
- Automatic backups (point-in-time restore up to 35 days)
- Built-in high availability (99.99% SLA)
- Automatic performance tuning
- Serverless option (auto-pause when idle, pay only when active)
- Elastic pools (share resources across multiple databases)
Azure SQL Managed Instance
Near-100% SQL Server compatibility with PaaS management. Designed for migrating existing on-premises SQL Server databases to Azure with minimal changes.
Best for: Lift-and-shift migration of existing SQL Server workloads that need features not available in SQL Database (like cross-database queries, SQL Agent, linked servers).
Tom’s scenario: Pacific Freight has an on-premises SQL Server with stored procedures, SQL Agent jobs, and cross-database queries. Managed Instance lets them move to Azure without rewriting their application.
Key features:
- Almost all SQL Server features supported
- VNet integration (network isolation)
- SQL Agent for scheduled jobs
- Cross-database queries
- Managed by Azure (patching, backups, HA)
SQL Server on Azure Virtual Machines
Full control — you get a VM running Windows or Linux with SQL Server installed. You manage everything: the OS, SQL Server configuration, patching, backups.
Best for: When you need full OS access, custom configurations, or specific SQL Server features/versions that Managed Instance doesn’t support.
When to choose this:
- You need a specific SQL Server version or edition
- You need OS-level access for third-party software
- You’re using features that require full server control
- Temporary: migration staging before moving to Managed Instance
| Feature | SQL Database | Managed Instance | SQL Server on VMs |
|---|---|---|---|
| Service model | PaaS (fully managed) | PaaS (near-full compatibility) | IaaS (you manage) |
| Best for | New cloud apps | Migrating existing SQL Server | Full control needed |
| Management | Azure handles everything | Azure handles most things | You handle OS + SQL Server |
| SQL compatibility | Most features | Nearly 100% | 100% (it IS SQL Server) |
| Cost | Lowest (serverless option) | Medium | Highest (VM + licence) |
| High availability | Built-in | Built-in | You configure it |
| Cross-DB queries | No (single DB focus) | Yes | Yes |
Purchasing models: DTU vs vCore
Azure SQL Database offers two purchasing models:
- DTU (Database Transaction Unit): A bundled measure of compute, storage, and I/O. Simple to understand — choose a tier (Basic, Standard, Premium) and get a pre-defined package. Good for predictable workloads.
- vCore: Choose CPU cores and memory separately. More flexible. Good for workloads that need specific configurations. Also supports the serverless tier (auto-scales and auto-pauses).
For DP-900, just know that both exist. You don’t need to calculate DTU values.
Exam tip: choosing the right Azure SQL option
Look for these signals:
- “New cloud application, minimal management” → Azure SQL Database
- “Migrate existing SQL Server with minimal code changes” → Managed Instance
- “Need specific SQL Server version or OS access” → SQL Server on VMs
- “Cross-database queries or SQL Agent required” → Managed Instance (not SQL Database)
- “Pay only when the database is active” → Azure SQL Database (serverless)
Flashcards
Knowledge check
Jake is building a new SaaS application for CloudPulse. He wants minimal management overhead and automatic scaling. Which Azure SQL option should he choose?
Pacific Freight has an on-premises SQL Server with cross-database queries, SQL Agent jobs, and VNet requirements. Tom needs to move it to Azure with minimal code changes. Which option?
🎬 Video coming soon
Next up: Open-Source Databases on Azure — Azure isn’t just SQL Server. It also hosts MySQL and PostgreSQL.