Speed Up the Popular Names Query SQLChallenge (46 minutes)

You’ve got a query that is just too slow!

Your challenge

Can you speed up the “Popular Names” query by ONLY making changes to the T-SQL?

Challenge difficulty

This is a 200-300 level challenge. If you have encountered this exact problem before, it could be a “quick solve,” but I’ve tested this on some smart folks who took a while to crack it!

Scripts

Grab the scripts at https://github.com/LitKnd/SQLWorkbooks/tree/main/speed_up_popular_names_sqlchallenge

Lessons

A tour of the Popular Names query (7 minutes)

Demo: Quick fix solutions (16 minutes)

Demo: A parameterized plan (8 minutes)

Demo: Stepping through a tuning process (11 minutes)

Verifying the results - and a recap (4 minutes)