Viewing 15 posts - 5,671 through 5,685 (of 22,211 total)
It's filtering 14 days here:
WHERE exec_date >= dateadd( day, -14, getdate() )
So, change the -14 to -1 and you're pretty much finished if everything else is working for you.
I don't...
August 20, 2015 at 12:15 pm
But you can create a nonclustered columnstore with a row-based clustered index.
August 20, 2015 at 10:59 am
Rebuilding an index updates the statistics at the same time. So the order in which you run these things does matter. Understand that if an index is not rebuilt, it...
August 20, 2015 at 2:53 am
After reading through all this excellent advice, the only thing I'd add is a question. Do you really need DISTINCT? That's adding quite a lot of overhead on top of...
August 20, 2015 at 2:50 am
I like what Jason did. As soon as you start seeing correlated sub-queries like that, usually the best approach is either a JOIN or an APPLY.
August 20, 2015 at 2:39 am
Sean Lange (8/19/2015)
August 19, 2015 at 9:44 am
If you hit problems with the book, you can always post questions here.
August 19, 2015 at 5:26 am
Here's the documentation on how to use ATTACH.
August 19, 2015 at 4:09 am
BL0B_EATER (8/14/2015)
Grant Fritchey (8/13/2015)
Eric M Russell (8/13/2015)
August 14, 2015 at 8:46 am
The fact that it ran differently on your machine could very easily be because it compiled a new, and better, execution plan on your machine. Also, what about blocking and...
August 14, 2015 at 8:43 am
They should be. They don't have to be. I'd sure put them up there. You'll pay for those VMs, but those costs should, by and large, be less than moving...
August 13, 2015 at 1:06 pm
Eric M Russell (8/13/2015)
August 13, 2015 at 12:12 pm
That makes absolute sense.
August 13, 2015 at 12:11 pm
Interesting. Then it prefers to use an average of the statistics and a generic plan, not a specific plan based on a value. Sounds like it might be bad parameter...
August 13, 2015 at 11:49 am
Viewing 15 posts - 5,671 through 5,685 (of 22,211 total)