Articles

Page 10 of 11 — showing articles 163 to 180 of 188

Seeking Without Indexes

Elementary

Singleton seeks, range scan seeks, multiple seeks in one, and a seek on a heap with no indexes

Is it a Seek or a Scan?

Seek or Scan?

Singleton seeks and seeks with range scans. Multiple seeking operations in a single SQL Server execution plan operator.

When is a Seek not a Seek?

It's a Puzzle

SQL Server can perform multiple index seeking operations in a single Index Seek operator.

Heaps of Trouble?

Hash Join

How a nested loops join with Eager Index Spools can be faster than a hash join.

Sequence Tables

Sequence

How to properly implement a custom Sequence Table facility, safe under high concurrency, and able to pre-allocate a range of values.

A Tale of Two Index Hints

Story Time

A detailed look at the differences between the INDEX(0) and INDEX(1) SQL Server table hints.

Inside the Optimizer: Plan Costing

Plan Costing

How the SQL Server query optimizer calculates plan operator costs. Adjusting the cost model with DBCC SETCPUWEIGHT and DBCC SETIOWEIGHT.

Sorting, Row Goals, and the TOP (100) Problem

Row Goals

The Top N Sort operator uses different implementations depending on the number of rows requested. For up to 100 rows it uses replacement selection and will never spill to tempdb.

Row Goals and Grouping

Rowing Goal

Why SQL Server will choose a Hash Match Flow Distinct operator when a row goal is present. Other options for grouping, and when they are chosen.

Inside the Optimizer: Row Goals In Depth

Row Goals in Depth

SQL Server does not always optimize to return the full result set. Various query features can introduce a "row goal", which aims to produce the first few rows quickly.

The Impact of Non‑Updating Updates

Impact

SQL Server optimizations for UPDATE statements that do not change data values. Covers logging, dirty pages, and avoiding the update completely.