The SQL Server Performance Tasting Menu: How Trivial Plans Can Hurt Query Performance

Trivially Yours


Going Further


If this is the kind of SQL Server stuff you love learning about, you’ll love my training. I’m offering a 75% discount to my blog readers if you click from here. I’m also available for consulting if you just don’t have time for that and need to solve performance problems quickly.



2 thoughts on “The SQL Server Performance Tasting Menu: How Trivial Plans Can Hurt Query Performance

  1. It’s interesting that for a “SELECT COUNT(*) FROM table” query, SQL Server will use a TRIVIAL optimization level, even though it still has to make a decision. It has to decide which of the indexes on the table to scan – either the clustered index or one of many possible nonclustered indexes.

    1. Sure, but as far as costing decisions go, you’re still maintaining the same plan shape, so it’s more a matter of picking the “smallest” index to read from. I’d consider that a trivial decision compared to other stuff.

Comments are closed.