Differences Between Actual & Estimated Plans

SQL Server, T-SQL
I have, in the past, made way too much of the need for Actual Plans when doing performance troubleshooting. The primary reason for this is to get the Actual Plan in order to see the differences between the Actual and Estimated Row Counts as a means of understanding how the optimizer saw the data. But, is that the only thing that's different between Actual & Estimated Plans? Well, pretty much, yeah. I took two fairly average execution plans from SQL Server 2014 and ran them through Altova's XML Spy, which does XML comparisons similar to how Redgate SQL Compare will compare two data structures for you. Here is every single difference I found. Everything was additional information in the Actual Plan. In the information for the first operator, in my case,…
Read More

Hey Kids! Let’s Put on a Show at the Old Barn

Azure, Database Lifecycle Management, DevOps, PASS, SQL Server, T-SQL
Alternate Title: I'm traveling a bunch. Let's get together and talk. A bunch of trips and presentations coming up, so I thought I'd share. First, I'll be SQL Saturday Omaha for my first time ever presenting in Nebraska. I'm excited to add this state to my list (which is almost over 40 now). If you're not doing anything August 15th, let's have a chat. Next, fingers crossed, I'll get selected to fly back to my home state, Oklahoma, to go to SQL Saturday OKC. These guys put on a great event and hey, it's Oklahoma so how can it be bad. I hope they announce soon. I need to schedule my flights. This one is on August 29th. September also has several events. First, I'll be at SQL Saturday Las…
Read More

Grant’s Fly-by-night Leadership Course – The Plan

Professional Development
Get a better name Define my personal goals for the course I won’t be sharing these with you. I may share them with my Inner Circle (defined below). I’m thinking this is a 2-3 year commitment I’m making. I need to have my own set of measurements to ensure that this will be worth the time and effort that I’m putting into it. Define a set of principles and goals for the course I want this course to have meaningful aim. It’s not, absolutely not, about management. Management and Leadership are two different things. This is about being a leader. It must have a purpose. The goals defined here, and like everything else, subject to change over time, will set the tone for each of the other choices. Here's another…
Read More

SQL Server Management Studio – Footloose and Fancy Free

Azure, SQL Server
That's right. There's been a divorce. SQL Server Management Studio (SSMS) has been divorced from the server product. In fact, Microsoft is inviting you to the new SSMS coming out party. I'm pretty excited about this. While I'm very comfortable in SSMS, to a large degree, it's like that old pair of jeans that you've worn for the last 10 years. They're comfortable too. Well, maybe a little tight when you pull them on out of the wash. One of the knees is gone. The legs are frayed so much it almost looks intentional. You just noticed a hole in the bottom. The zipper is acting up... Yeah, OK. These jeans have had it. So has SSMS. The plan from Microsoft is to upgrade SSMS independently from the boxed product. In fact, since one of…
Read More

How Do You Know You’re Good At Your Job?

Professional Development
You've been working as a DBA for X number of years. How do you know you're good at it? Heck, you've been doing any sort of job for a while. How can you measure whether or not you're competent? The single best measure isn't how much work you do, your accomplishments, the number of databases designed, whatever measure you have. That's not it. The real measure, the one that counts, how do you perform when everything goes south? When that server goes offline or that database develops corruption or that SSIS package fails or, heck, you get a request to fix something that's broken, even non-technical stuff like an incorrect W-2 form (fighting this battle currently)? Did you run around like your hair was on fire? Did you sit there…
Read More

But I Don’t Have a Test Server…

Database Lifecycle Management, DevOps, SQL Server, T-SQL
I frequently see statements on forums along the lines of "I don't have a test server, so I'm going to do something I've never done before directly on my production servers..." This is usually followed by questions along the lines of: But that's OK and I won't get fired, right? So how do I know if it worked? Is that dangerous? The replies are: No. You should be fired You won't By All the Gods! Yes! It's stupidly, insanely, I don't really like my production server, my data, my boss, or my job, dangerous. Yes. I understand. You're working for a not-for-profit, so you can't afford tons of new servers. You're looking at a 50tb production server of which, you can't make a copy. Your bosses just don't want to spend the…
Read More

Speaker of the Month: June 2015

Professional Development
With my travel schedule, I don't always get out to events where I can see a community speaker. Sometimes, I just see pros. That's the case this month. Instead of skipping the month entirely, which feels wrong, I've decided to do a special award. Speaker of the Month for June 2015 are all the speakers (except me) on SQL Cruise Mediterranean 2015. I've said it before and I don't mind repeating myself, SQL Cruise changes people's careers. There are a lot of reasons for this. The number one reason is all the work that Tim & Amy Ford do to put together the cruise, create the itinerary, ensure plenty of structured and unstructured time on the boat to ensure intense interaction, and all the rest of the stuff that they…
Read More

Leadership Training Possibility

Professional Development
I know a few people in the SQL Server community who have been involved in Scouting. A couple of them have taken or helped lead Scoutings leadership training program known as Wood Badge. It's an amazing program. I won't even attempt to tell you what Wood Badge has done for me and what it does for Scouting. Suffice to say, Wood Badge helped to make me a better person and in return, I helped make Scouting better. What's this have to do with SQL Server? Not much really. But, what does it have to do with you and your career? Tons. It was pointed out to me that there's an Oracle users group that actually runs a leadership program. You can read about it here. It strikes me that, maybe this…
Read More

Speaker of the Month: May 2015

Misc
When I attend sessions at events, I try to mix it up. I'll go to a session that, really, I probably will never use the information, just to expand my knowledge level a little. I also go to sessions by the masters so that I can try to expand my skill set. I go to sessions on topics that I feel like I know well just to reinforce my own learning and understanding. That's where I got the Speaker of the Month for May 2015, Denis McDowell (t). I went to his session titled DevOps for the DBA at SQL Saturday #380 in New York City. I present pretty regularly on this topic and I've helped build multi-day training courses on it. Seriously, I feel like I probably know it.…
Read More

Parallelism and Columnstore Indexes

T-SQL
Columnstore indexes are fascinating and really cool. Unfortunately, they're adding an interesting new wrinkle to an old problem. What's the Cost Threshold for Parallelism set to on your server? If you just said "The whatsis of whositz?" then the value is 5. The cost threshold is the point at which the estimated cost of an execution plan goes from definitely serial to possibly parallel. This default was set for SQL Server 2000 and hasn't been changed since. I've long argued, loudly, that it's too low. I've suggested changing it to a much higher value. My advice has gone from 35 to 50 and several places in between. You could just look at the median or the mode of costs on your system and use the higher of those values as…
Read More