SQL Optimization

I’m the SQL guru at work, but I have no idea how I got to be that person. It just seemed to have happened. I know SQL better than a lot of other people. I’ve known some people who were better at it, and I followed their examples. Eventually, enough soaks into your brain that you gain new tools in your toolbox. Then you change jobs and you find that you are the local expert.
My work encourages me to continue self-development. They help do this by giving me access to Pluralsight so I learn more about technologies. Since I have doubts about my guru-ness of SQL, I thought I would take some courses on it. Mostly I wanted to learn how to optimize the queries. I’ve made some basic queries and watch them take minutes to perform the task. Then you make a few small changes and your result is back in under a second. I want to be more confident in my ability to do that.
The course titled “SQL Server: Optimizing Ad Hoc Statement Performance” seemed like it would do that. After about two hours in, I got the impression this is not actually going to help me optimize my SQL, but optimize how to construct the SQL so that it is cached properly. (I’ll finish the course so that I can be sure of my initial suspicion.)
I started to think that I could make a better course on SQL. Then I thought, why shouldn’t I? I know a lot of SQL, and I could write a document of all the tricks I’ve learned to improve the performance of it. Heck, that is what I’m frequently doing at work.
The biggest issue is one of self-doubt. I could write a lot of good tips. But I would always wonder if one of them was just wrong and thus negate the credibility of all of the other tips. I’m writing it out here to point out that that is silly. I really should write this document. At the very least so I can reference it myself after I’ve forgotten my tricks.

One thought on “SQL Optimization

Comments are closed.