Smartly Academy

Smartly Academy

The C# Lab

Change Tracking — How Your ORM Knows What You Did

We can query. We can materialize. We can join. But saving changes means knowing what changed — and that's where things get philosophically interesting.

Anto Semeraro's avatar
Anto Semeraro
Mar 06, 2026
∙ Paid

Here's something that should bother you about Entity Framework:

var customer = await context.Customers.FindAsync(42);
customer.Name = "New Name";
await context.SaveChangesAsync(); // How does it know?

You loaded an entity. You changed a property. You called SaveChanges. And the ORM generated a precise UPDATE Customers SET Name = @p0 WHERE Id = @p1 — updat…

User's avatar

Continue reading this post for free, courtesy of Anto Semeraro.

Or purchase a paid subscription.
© 2026 Antonello Semeraro · Privacy ∙ Terms ∙ Collection notice
Start your SubstackGet the app
Substack is the home for great culture