SQL Server Execution Plans
I write quite frequently about SQL Server Execution Plans. I started in that area just because that’s how you figure out what a query is doing and sooner or later, we all have to tune a query. I found...
View ArticleSQL Server XQuery Against Execution Plans
One of the greatest things about all the DMOs is how you can combine the information they present to you with execution plans. It allows you to see what a query is doing, even as it’s executing,...
View ArticleDatabase Backups: Things You Need To Do Now
I want to say a few things about database backups that you need to know. Wait a minute, haven’t you written about backups before? Why, yes. Yes I have. Aaand… you’re doing it again because? Have you...
View ArticleExecution Plans, What Do I Look At?
The question came up, what are the top 3-5 things that you look at in a query. I realized then that I hadn’t really written them down. There are some areas that let me know pretty much immediately...
View ArticleExecution Plan for a User Defined Function
When you execute a multi-statement user-defined function you may see an execution plan that looks something like this: It appears as if the cost of the UDF is free. This is especially true if you use...
View ArticleNever, Ever Use Clustered Indexes
This whole concept of the clustered index as a foundational structure within SQL Server is just plain nuts. Sure, I get the concept that if a table has a clustered index, then that index actually...
View ArticleGuest Blog
I was given the opportunity to put together a guest blog post for the MVP blog. I did a little something on determining whether or not you have high memory use through the use of a DMO. Check it out.
View ArticleQuerying Information from the Plan Cache, Simplified
One of the great things about the Dynamic Management Objects (DMOs) that expose the information in plan cache is that, by their very nature, they can be queried. The plans exposed are in XML format, so...
View Article24 Hours of PASS, Fall 2012
It’s time to get your learn on again. The schedule for the Fall 24 Hours of PASS is up and ready for registration. This is the Summit preview session, so many (most, all) of the speakers are showing...
View ArticleSQL Server vs. Oracle
Just so we’re clear, I use SQL Server. I like SQL Server. But, this doesn’t mean I have anything against Oracle. It’s fine. It’s good. But, I know very little about it. However, throughout my career...
View ArticleInterviewing a DBA
I’m not a fan of trivia style interview questions. Yes, I ask a few because you have to in order to immediately eliminate the completely unqualified applicants. Even those types of questions, in my...
View ArticleClustered Indexes Have Statistics Too
It may seem obvious, but I’ve heard more than one person suggest to me that statistics on a clustered index just don’t matter. That if the clustered index can satisfy a given query, it’s going to get...
View ArticleSharing the Love
Just a few blog posts that you ought to go and read. First up, Tom LaRock maintains a listing of SQL bloggers split up into various cleverly named groups to show you where to go to get good...
View ArticleAre Foreign Keys Better Than Indexes?
When I first saw this question I thought to myself, “Self. Don’t you think that’s comparing apples to hammers? Yes, Self, I’m pretty sure it is. Good, I thought so too, self. Yeah, me too.” After...
View ArticleFinding Ad Hoc Queries with Query Hash
I was presenting a session on how to read execution plans when I received a question: Do you have a specific example of how you can use the query hash to identify similar query plans. I do, but I...
View ArticleQuery Tuning in Dallas
Let’s have some fun. This Friday, November 1, 2013, I’m putting on an all day seminar on query tuning. It’s set up as a pre-conference event for SQL Saturday 255 in Dallas. It’s a 200 level course on...
View ArticleDatabase in Source Control
Many years ago, I was working with a great DBA. Seriously, a very smart and capable guy. He told me, “We need to put the database into source control, just like app code.” And I just laughed. Not...
View ArticleTime for a Quick Rant
This is an actual quote from what we can only assume is a functional human being: The database is very big so we stopped taking backup’s. Eight lords a leaping are you kidding me? Seriously! Seriously?...
View ArticleThe CASE Statement and Performance
In case you don’t know, this query: UPDATE dbo.Test1 SET C2 = 2 WHERE C1 LIKE '%33%'; Will run quite a bit slower than this query: UPDATE dbo.Test1 SET C2 = 1 WHERE C1 LIKE '333%'; Or this one: UPDATE...
View ArticleLet’s Talk Query Tuning
I spend quite a bit of time writing about query tuning on this blog. I’ve written (re-written and am actively re-writing) books on query tuning. But what I like most is talking about query tuning. I...
View Article
More Pages to Explore .....