This post is a part of the DP-800: Developing AI-Enabled Database Solutions Exam Prep Hub.
This topic falls under these sections:
Secure, optimize, and deploy database solutions (35–40%)
--> Integrate SQL solutions with Azure services
--> Handle changes by using change event streaming (CES), change data capture (CDC), Change Tracking, Azure Functions with SQL trigger binding, or Azure Logic Apps
Note that there are 10 practice questions (with answers) at the end of each section to help you solidify your knowledge of the material. Also, there are 4 practice tests with 30 questions each available from the hub's main page below the exam topics section.
Introduction
Modern applications rarely operate in isolation. A single database update often needs to trigger downstream actions such as updating search indexes, synchronizing data warehouses, refreshing caches, sending notifications, invoking APIs, or triggering AI pipelines.
Microsoft SQL Server and Azure SQL provide several mechanisms to detect and react to data changes. The DP-800 exam expects candidates to understand the capabilities, strengths, limitations, and appropriate use cases for each technology.
The primary technologies include:
- Change Data Capture (CDC)
- Change Tracking
- Change Event Streaming (CES)
- Azure Functions with SQL Trigger Binding
- Azure Logic Apps
Understanding when and why to use each technology is more important than memorizing implementation details.
Why Change Detection Matters
Applications often need to know when data changes occur without continuously querying every table.
Examples include:
- Synchronizing CRM and ERP systems
- Triggering AI workflows after new customer data arrives
- Updating recommendation engines
- Refreshing search indexes
- Sending order confirmation emails
- Replicating data into Microsoft Fabric
- Populating analytical data lakes
- Updating Power BI semantic models
Without an efficient change detection mechanism, applications would have to repeatedly scan entire tables, resulting in:
- Poor performance
- Increased costs
- Higher latency
- Unnecessary resource utilization
Overview of Available Technologies
| Technology | Detects Inserts | Updates | Deletes | Provides Changed Values | Typical Use |
|---|---|---|---|---|---|
| Change Tracking | Yes | Yes | Yes | No | Lightweight synchronization |
| Change Data Capture | Yes | Yes | Yes | Yes | ETL and replication |
| Change Event Streaming | Yes | Yes | Yes | Event stream | Event-driven architectures |
| Azure Functions SQL Trigger | Yes | Yes | Yes | Current row | Serverless processing |
| Azure Logic Apps | Yes | Yes | Yes | Depends on connector | Workflow automation |
Change Data Capture (CDC)
What is CDC?
Change Data Capture records every data modification that occurs within selected database tables.
Unlike Change Tracking, CDC stores:
- The type of operation
- Before and after values (where applicable)
- Transaction information
- Log Sequence Numbers (LSNs)
- Timestamps
CDC reads changes directly from the SQL Server transaction log instead of requiring application modifications.
How CDC Works
- User modifies data.
- SQL writes changes to the transaction log.
- CDC captures the changes.
- Changes are written into CDC system tables.
- Applications or ETL tools read the captured changes.
Application │ ▼SQL Table │Transaction Log │ ▼CDC Capture Process │ ▼CDC Change Tables │ ▼ETL / Azure Data Factory / Fabric
Information Stored by CDC
For every change, CDC stores:
- Insert
- Update
- Delete
- Transaction sequence
- Changed columns
- Original values
- New values
- Commit time
- Log sequence number
This provides a complete history of modifications.
Advantages of CDC
Minimal application changes
Applications continue performing normal INSERT, UPDATE, and DELETE operations.
Incremental processing
Instead of processing millions of rows:
Yesterday:10 million rowsToday:Only 1,250 rows changedCDC processes only 1,250 rows.
This dramatically improves ETL performance.
Supports Historical Analysis
CDC retains detailed change history.
Example:
Customer Name
Original:
John Smith
Updated:
John A. Smith
CDC preserves both versions.
Common CDC Use Cases
- Azure Data Factory incremental loads
- Microsoft Fabric ingestion
- Data warehouse updates
- Database replication
- AI training pipelines
- Audit solutions
- Event publishing
- Synchronizing microservices
Limitations
CDC:
- Uses additional storage
- Requires SQL Agent jobs (SQL Server)
- Introduces some overhead
- Retention must be managed
- Generates additional transaction log activity
Change Tracking
What is Change Tracking?
Change Tracking is a lightweight feature that records which rows have changed, but does not store the actual changed values.
Instead, it stores metadata indicating:
- Row changed
- Row deleted
- Version number
Applications retrieve the latest row directly from the table.
How Change Tracking Works
Instead of saving old values:
CustomerID 101 changed.
The application retrieves:
SELECT *FROM CustomersWHERE CustomerID = 101
Only the current version is available.
Advantages
Very lightweight.
Minimal storage.
Minimal performance impact.
Simple synchronization.
Fast processing.
Limitations
Cannot determine:
Old value
↓
New value
Only knows:
Row changed
No historical audit.
No before-and-after comparison.
Best Use Cases
Mobile synchronization
Offline applications
Client synchronization
Web applications
Caching
Incremental refresh
Applications only needing current data
CDC vs Change Tracking
| Feature | CDC | Change Tracking |
|---|---|---|
| Detect Inserts | Yes | Yes |
| Detect Updates | Yes | Yes |
| Detect Deletes | Yes | Yes |
| Stores Old Values | Yes | No |
| Stores New Values | Yes | No |
| Historical Data | Yes | No |
| Storage Usage | Higher | Lower |
| ETL Friendly | Excellent | Limited |
| Synchronization | Good | Excellent |
| Auditing | Excellent | Poor |
Choosing Between CDC and Change Tracking
Choose CDC when:
- Building ETL pipelines
- Loading data warehouses
- Creating audit systems
- Tracking complete history
- AI model retraining
- Replication
Choose Change Tracking when:
- Synchronizing mobile devices
- Synchronizing applications
- Detecting row changes only
- Performance is critical
- History is unnecessary
Change Event Streaming (CES)
What is Change Event Streaming?
Change Event Streaming is an event-driven approach that publishes database changes as events immediately after they occur.
Instead of applications polling for changes:
Did anything change?Did anything change?Did anything change?
The database immediately emits an event.
Event-Driven Architecture
INSERT Order │ ▼Database │ ▼Event Published │ ┌────┼────┐ ▼ ▼ ▼FunctionLogic AppService Bus
One database change can notify many downstream services simultaneously.
Advantages
Near real-time processing
Low latency
Highly scalable
Excellent for cloud-native applications
Supports asynchronous processing
Works well with event hubs and messaging systems
Common Scenarios
Order processing
Inventory updates
Recommendation engines
AI pipelines
Search indexing
Notifications
Microservices
IoT
Streaming analytics
Benefits over Polling
Polling example:
Check database every minute
Potential issues:
- Delayed processing
- Unnecessary database queries
- Higher compute costs
Event streaming:
Change occurs↓Immediate notification
Much more efficient.
Azure Functions with SQL Trigger Binding
Overview
Azure Functions provide a serverless compute platform capable of automatically executing code when database changes occur.
SQL Trigger Binding enables Azure Functions to react to SQL data modifications without requiring custom polling logic.
Typical workflow:
Database Change↓SQL Trigger↓Azure Function↓Business Logic
Common Scenarios
Automatically:
- Send emails
- Generate invoices
- Update search indexes
- Invoke AI models
- Call REST APIs
- Update Cosmos DB
- Write to Azure Storage
- Publish Service Bus messages
Benefits
Serverless
Automatic scaling
Pay only for executions
Minimal infrastructure management
Easy integration with Azure services
Supports event-driven architectures
Example Scenario
A customer places an order.
INSERT Orders
The SQL trigger starts an Azure Function.
The function:
- Validates inventory
- Sends confirmation email
- Updates recommendation engine
- Notifies shipping
- Publishes event
No manual polling required.
Azure Logic Apps
What Are Logic Apps?
Azure Logic Apps are low-code workflow automation services that integrate SQL databases with hundreds of Microsoft and third-party services.
Rather than writing custom code, workflows are built visually.
Example:
SQL Row Updated↓Logic App↓Teams Notification↓Outlook Email↓SharePoint Update↓CRM Update
Common SQL Integrations
SQL Server
Azure SQL Database
Microsoft Dataverse
Dynamics 365
Salesforce
Microsoft Teams
SharePoint
Azure Storage
Azure Service Bus
Azure Event Grid
Power Automate
Typical Workflow
Customer Created↓Logic App↓Create CRM Record↓Send Welcome Email↓Create Help Desk Ticket↓Notify Sales Team
Advantages
Low-code
Rapid development
Hundreds of connectors
Visual designer
Built-in retry policies
Error handling
Scheduling
Monitoring
Enterprise integration
Limitations
Logic Apps are ideal for orchestration and workflow automation but are not intended for high-throughput transactional processing where custom code or event streaming solutions may provide better scalability and lower latency.
Choosing the Right Technology
| Requirement | Recommended Solution |
|---|---|
| Incremental ETL | CDC |
| Data Warehouse Loading | CDC |
| Audit History | CDC |
| Mobile Sync | Change Tracking |
| Cache Refresh | Change Tracking |
| Event-Driven Processing | Change Event Streaming |
| Serverless Business Logic | Azure Functions SQL Trigger |
| Workflow Automation | Azure Logic Apps |
| AI Pipeline Trigger | Azure Functions or CES |
| Multi-System Integration | Logic Apps |
Best Practices
Enable Only What You Need
Enable CDC or Change Tracking only on tables that require change detection.
Monitor Storage
CDC tables can grow quickly.
Implement retention policies and cleanup jobs.
Prefer Event-Driven Architectures
Avoid continuous polling whenever possible.
Use:
- CES
- Azure Functions
- Event Grid
- Service Bus
for scalable cloud-native applications.
Separate Operational and Analytical Workloads
Use CDC to move transactional data into analytical platforms instead of querying production systems directly.
Secure Integration Endpoints
Protect Azure Functions and Logic Apps using:
- Microsoft Entra ID
- Managed identities
- Azure Key Vault
- Least privilege access
- Network restrictions where appropriate
Monitor Reliability
Track:
- Failed executions
- Retry attempts
- Dead-letter queues
- Function failures
- Logic App run history
- Event delivery failures
DP-800 Exam Tips
Remember these common exam distinctions:
- CDC records complete data changes, including inserted, updated, and deleted values, making it ideal for ETL, auditing, and replication.
- Change Tracking records only that a row changed, making it a lightweight solution for synchronization scenarios.
- Change Event Streaming supports near real-time, event-driven architectures by publishing change events to downstream consumers.
- Azure Functions with SQL Trigger Binding are best when database changes should execute custom serverless code automatically.
- Azure Logic Apps are the preferred choice for orchestrating business workflows and integrating SQL databases with Azure and third-party services through low-code connectors.
- When selecting a technology, evaluate latency requirements, scalability, historical tracking needs, operational overhead, and integration requirements rather than choosing a single solution for every scenario.
Summary
Modern SQL applications extend well beyond traditional databases, serving as event sources for cloud-native architectures, AI pipelines, analytics platforms, and business workflows. Microsoft provides several complementary technologies to detect and process database changes, each optimized for different scenarios.
For the DP-800 exam, you should understand not only how these technologies work, but also when to choose one over another. CDC excels at incremental ETL and auditing, Change Tracking offers lightweight synchronization, Change Event Streaming enables real-time event-driven systems, Azure Functions execute custom business logic in response to changes, and Azure Logic Apps simplify workflow automation across enterprise services.
A solid understanding of these tools will help you design scalable, maintainable, and performant AI-enabled database solutions in Azure.
Practice Exam Questions
Question 1
A company loads data from an Azure SQL Database into a Microsoft Fabric warehouse every hour. The ETL process should retrieve only rows that have changed since the previous load, including the previous and new values of updated rows.
Which technology should you recommend?
A. Change Tracking
B. Change Data Capture (CDC)
C. Azure Logic Apps
D. Azure Functions with SQL Trigger Binding
Correct Answer: B
Explanation
CDC is specifically designed for incremental data movement scenarios. It captures inserts, updates, and deletes directly from the transaction log and stores detailed information about each change, including before and after values where applicable.
Why the other options are incorrect:
- A: Change Tracking identifies changed rows but does not store previous values.
- C: Logic Apps orchestrate workflows but do not capture database changes.
- D: Azure Functions respond to events but are not intended to maintain historical change data for ETL.
Question 2
A mobile application periodically synchronizes customer records with an Azure SQL Database. The application only needs to know which rows have changed since the last synchronization and does not require historical values.
Which feature is most appropriate?
A. Change Event Streaming
B. Azure Functions SQL Trigger
C. Change Tracking
D. CDC
Correct Answer: C
Explanation
Change Tracking is optimized for synchronization scenarios. It records that rows have changed while minimizing storage and processing overhead.
Why the other options are incorrect:
- A: CES is designed for event-driven architectures.
- B: Azure Functions execute custom code rather than maintaining synchronization metadata.
- D: CDC stores detailed change history, which is unnecessary here.
Question 3
An online retailer wants every new order inserted into the Orders table to immediately trigger inventory updates, shipping notifications, and fraud detection.
Which solution best supports this requirement?
A. Scheduled polling queries
B. Change Tracking
C. Change Event Streaming (CES)
D. Nightly ETL jobs
Correct Answer: C
Explanation
CES enables near real-time event publishing whenever database changes occur. Multiple downstream systems can subscribe to the same event without repeatedly querying the database.
Why the other options are incorrect:
- A: Polling introduces unnecessary latency and database load.
- B: Change Tracking is intended for synchronization rather than event processing.
- D: Nightly ETL introduces unacceptable delays.
Question 4
A database update should automatically execute custom C# code that calls several REST APIs and writes audit information to Azure Storage.
Which Azure service should you recommend?
A. Azure Functions with SQL Trigger Binding
B. CDC
C. Change Tracking
D. SQL Agent Job
Correct Answer: A
Explanation
Azure Functions with SQL Trigger Binding automatically execute custom code when qualifying database changes occur, making them ideal for serverless business logic.
Why the other options are incorrect:
- B: CDC records changes but does not execute code.
- C: Change Tracking simply records row modifications.
- D: SQL Agent jobs rely on scheduled execution rather than event-driven processing.
Question 5
Which statement correctly compares Change Tracking and Change Data Capture?
A. CDC captures complete change history while Change Tracking records only that rows changed.
B. Change Tracking captures previous values while CDC does not.
C. Both features store identical information.
D. CDC only tracks INSERT operations.
Correct Answer: A
Explanation
CDC stores detailed information about every change, including inserts, updates, deletes, timestamps, and transaction metadata. Change Tracking only identifies which rows have changed.
The remaining options are incorrect because they reverse the capabilities or incorrectly describe CDC.
Question 6
A business analyst wants to automate the following workflow without writing custom code:
- Detect a new customer record.
- Send an Outlook email.
- Post a Microsoft Teams notification.
- Update a SharePoint list.
Which solution is the best choice?
A. CDC
B. Azure Logic Apps
C. Change Tracking
D. SQL CLR
Correct Answer: B
Explanation
Azure Logic Apps provide low-code workflow automation with hundreds of built-in connectors, making them ideal for orchestrating business processes across Microsoft services.
Why the other options are incorrect:
- A: CDC captures changes but does not automate workflows.
- C: Change Tracking only records modified rows.
- D: SQL CLR requires custom coding and is not intended for cloud workflow automation.
Question 7
A development team currently polls the database every minute to determine whether new records have been inserted.
What is the primary disadvantage of this design?
A. It reduces database normalization.
B. It prevents indexing.
C. It increases transaction isolation.
D. It generates unnecessary database workload and introduces latency.
Correct Answer: D
Explanation
Polling repeatedly queries the database even when no changes exist, increasing resource consumption while delaying event processing.
Event-driven solutions such as CES or Azure Functions eliminate this inefficiency.
Question 8
Which technology is most appropriate when an organization must maintain a complete historical record of all row changes for regulatory auditing?
A. Azure Logic Apps
B. Change Tracking
C. Change Data Capture
D. Azure Functions
Correct Answer: C
Explanation
CDC preserves detailed information about inserts, updates, deletes, transaction sequence numbers, and timestamps, making it ideal for compliance and auditing.
The other technologies either automate workflows or identify changes without preserving historical values.
Question 9
Which feature is specifically intended to minimize synchronization overhead by storing only metadata about changed rows?
A. Azure Functions SQL Trigger
B. Change Tracking
C. Change Event Streaming
D. Azure Event Grid
Correct Answer: B
Explanation
Change Tracking records lightweight metadata that indicates which rows have changed, allowing applications to retrieve only the latest row versions.
The other options serve different purposes:
- Azure Functions execute code.
- CES publishes events.
- Event Grid distributes events but does not track database modifications.
Question 10
A solution architect is selecting a technology for an event-driven microservices architecture. Multiple independent services must react immediately whenever product inventory changes.
Which solution best satisfies this requirement?
A. Nightly ETL processing
B. Change Tracking
C. Database polling every five minutes
D. Change Event Streaming (CES)
Correct Answer: D
Explanation
CES is designed for event-driven systems where multiple subscribers consume database change events in near real time. It minimizes latency and reduces unnecessary database queries.
Why the other options are incorrect:
- A: Nightly processing is far too slow.
- B: Change Tracking is intended for synchronization rather than event broadcasting.
- C: Polling introduces unnecessary workload and delays.
Exam Tips
For the DP-800 exam, remember these key distinctions:
- Change Data Capture (CDC) is best for incremental ETL, auditing, replication, and historical change tracking.
- Change Tracking is designed for lightweight synchronization when only the fact that a row changed is needed.
- Change Event Streaming (CES) enables near real-time event-driven architectures by publishing database changes to downstream consumers.
- Azure Functions with SQL Trigger Binding are ideal for executing custom serverless code in response to database changes.
- Azure Logic Apps provide low-code workflow automation for integrating Azure SQL with Microsoft and third-party services.
- On the exam, Microsoft often presents multiple technologies that could work. Choose the one that best aligns with the business requirement, considering factors such as latency, historical tracking, automation, scalability, and operational overhead, rather than selecting the most feature-rich option.
Go to the DP-800 Exam Prep Hub main page
