
SQL Fundamentals
N+1 Queries: What the ORM Is Actually Doing
One query for the list, then one more for every item in it. The cost is per statement, which is why the profiler shows a fast database and a slow request.
· 3 min
articles
Every article on SQLPress — query performance, database internals, operations and the day-to-day craft of working with data.
14 articles

One query for the list, then one more for every item in it. The cost is per statement, which is why the profiler shows a fast database and a slow request.
· 3 min

An index the planner ignores is usually a row-estimate problem. The fix starts with what the optimizer expected, not with the index definition.
· 3 min