Now where did THAT estimate come from?

This page contains the description for my conference session “Now where did THAT estimate come from?”, and links to the slide deck and demo code used in this presentation.

Description

Target audience Experienced database developers and DBAs.
Short description Very detailed in-depth look at how SQL Server uses statistics and other information to estimate how many rows each execution plan operator will process.

Where appropriate, differences between the “new” and “legacy” versions of the cardinality estimator are pointed out.

Duration The ideal length for this session is 90 – 120 minutes, though it can be shortened to 60 minutes if needed.
Full abstract The SQL Server Query Optimizer makes its plan choices based on estimated rowcounts. If those estimates are wrong, the optimizer will very likely produce a poor plan. And there’s nothing you can do about it. Or is there?

In this session, you will learn exactly where these estimates come from. You will gain intimate knowledge of how statistics are built and maintained and how they are used to estimate row counts. But you will also learn how filters and joins influence those estimates.

Though the focus of this session is on understanding the causes of bad estimates, you will also learn ways to fix the problems and get better estimates – and hence, better performing queries.

Resources

Click here to download a ZIP file containing the slide deck and demo code used in this presentation.

(Note: my presentations tend to evolve over time, so the version you find here may not be an exact match for the version you witnessed)

Menu

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close