Roadmap › 3. Cloud & DevOps › Step 39
AzDB

Azure Databases — Azure SQL, Managed Instance, Cosmos DB, PostgreSQL and Migration

Choosing a database on Azure; Azure SQL Database (single database, elastic pools, DTU vs vCore, General Purpose / Business Critical / Hyperscale, serverless), Azure SQL Managed Instance and SQL Server on Azure VMs; security (firewall, private endpoints, Microsoft Entra authentication, managed identity, TDE, Always Encrypted, auditing), high availability, geo-replication, failover groups and backups/point-in-time restore; performance (Query Store, automatic tuning, Intelligent Insights); Cosmos DB (APIs, partition keys, RU/s, consistency levels), Azure Database for PostgreSQL/MySQL, Azure Cache for Redis; migrating on-premises SQL Server (DMA, Azure Database Migration Service) and cost optimisation.
What it is & where it is used
ServiceTypeChoose when
Azure SQL DatabasePaaS, one database (or elastic pool)New cloud apps on SQL Server — no server to manage
Azure SQL Managed InstancePaaS, near-100 % SQL Server instance compatibilityLift-and-shift of on-prem SQL Server using SQL Agent, cross-database queries, CLR, Service Broker, linked servers
SQL Server on Azure VMIaaSNeed full OS/instance control, SSRS/SSIS/SSAS on the same box, unsupported features
Azure Cosmos DBGlobally distributed NoSQL (multi-API)Massive scale, single-digit-ms reads, flexible JSON, multi-region writes
Azure Database for PostgreSQL (Flexible Server) / MySQLManaged open-source databasesApps built for Postgres/MySQL
Azure Cache for Redis / Azure Managed RedisIn-memory cacheCaching, sessions, leaderboards
Azure Synapse / Microsoft Fabric warehouseAnalyticsData warehousing and BI at scale

Azure SQL Database runs the same SQL Server engine (always the latest version), so T-SQL skills transfer directly — but some instance-level features differ (no SQL Agent in single databases — use Elastic Jobs/Azure Functions/Logic Apps; no cross-database queries without elastic query; no USE to switch databases).

Versions & history
YearMilestone
2010SQL Azure (first cloud SQL Server service)
2014–2016Azure SQL Database service tiers (Basic/Standard/Premium, DTU), elastic pools, geo-replication, Query Store, TDE by default
2017Cosmos DB (from DocumentDB), Azure Database for PostgreSQL/MySQL
2018SQL Managed Instance GA, vCore purchasing model, Hyperscale preview
2019Serverless compute tier, Hyperscale GA
2020–2022Azure SQL "family" branding, ledger, Azure AD-only auth, Cosmos DB serverless and autoscale
2023–2024Managed Instance next-gen General Purpose, free Azure SQL Database offer (per subscription), Hyperscale price reductions, vector search previews
2025Native vector type and JSON type in Azure SQL, SQL database in Microsoft Fabric, Cosmos DB vector search GA
Lifecycle

Moving a .NET app's database to Azure SQL:

  1. Assess the on-prem database (Azure Migrate / Data Migration Assistant / SQL Server migration extension in Azure Data Studio's successor tools) for compatibility and target size.
  2. Choose the target: Azure SQL Database (new/modern apps), Managed Instance (instance features), VM (full control).
  3. Provision with Bicep/Terraform/CLI: logical server, database, service tier, networking (private endpoint), Entra admin.
  4. Migrate schema + data: Azure Database Migration Service (online/offline), BACPAC import, transactional replication or log shipping (MI link) for minimal downtime.
  5. Switch the app: new connection string (managed identity), retry logic for transient faults, test performance.
  6. Operate: monitoring (Azure Monitor, Query Store), automatic tuning, alerts, backups/PITR, geo-replication/failover groups, cost reviews.
Tools used to develop
  • Azure Portal, Azure CLI (az sql), PowerShell (Az.Sql), Bicep/Terraform.
  • SSMS, VS Code MSSQL extension, sqlcmd / sqlpackage (BACPAC/DACPAC), SQL database projects (SDK-style) for schema CI/CD.
  • Azure Database Migration Service, Azure Migrate, Data Migration Assistant.
  • Monitoring: Query Performance Insight, Query Store, Azure Monitor metrics/alerts, Database Watcher, Defender for SQL.
  • Cosmos DB: Data Explorer, .NET SDK v3, Cosmos DB emulator.