Do you know when to use raw sql?
Loading last updated info...
Raw SQL comes with risks but sometimes it is the best solution.
Using raw SQL involves taking care of SQL injection and other risks, however there are a number of situations where it may be the best solution.
The most obvious is a SQL UPDATE statement which updates a large number of rows.
await context.Database.ExecuteSqlInterpolatedAsync($"UPDATE Employees SET Active = {activeState}", ct);
✅ Figure: Good example - Updating a large number of rows quickly with SQL