Free Webcast: My Favorite Query Hints
One of my favorite uses for dynamic SQL is to use them to inject query hints. Let's say you've got a stored procedure with a bunch of parameters, including a @StartDate and @EndDate date range. And let's say people usually use a small default date range, like the last week - but every now and then,…