Training SQL Server Newbies to Avoid Basic Database Mistakes

Missing indexes and forgetting to test backups

This week I'm going to explore a topic that might seem overly simple at face value, but hints at what might be some deep truths about the nature of the database business, and perhaps software development, in general.

Making the Same Mistakes Today

Indexes are important. All of your tables, at least those in an OLTP system, should probably have at least one index. I know that right now you're thinking, "You needed to tell us that indexes are important? Seriously?" In addition, backups are worthless unless you can restore them, so test you restores. Again, I suspect you’re thinking, "Seriously?"

Let me pivot to the deeper truth by getting in a time machine and dialing back 15 years or so. I was a hard-core OLTP tuning expert in the early and middle stages of my career. As I started to focus on performance tuning I still remember thinking, "This isn't rocket science. Maybe I can make a career out of it for a little while, but I can't possible ride this consulting gravy train forever. Eventually people will figure this stuff out on their own."

About a decade ago, I started my first company, and for a while my career focused much more on the business side of the company and I wasn't quite as technical as I used to be. Recently, I started another professional services company. I still focus more on the business side of things, but I've been doing a bit more technical work than I had done for a while. And I figured out that people still forget to put indexes on tables and still forget to test their backups. I have to admit that I was sort of surprised that these were still a problem. And then it occurred to me that the people making the mistakes today probably aren't the ones who were making the mistakes 10 or 15 years ago. The people no longer forgetting to put indexes on tables either learned, got fired, or moved on to other careers. But surprisingly (at least to me), many of the same basic mistakes are still being made.

Training New Generation of DBAs

So what does that say about education and passing the torch to the next generation of DBAs (and I suspect many other IT professionals)? Well I’m not entirely sure. But if I think about the medical profession, for example, I'm pretty sure that most doctors today know that leeches probably aren't the superlative cure-all that they were once thought to be. The point I'm trying to make is that I suspect that many other professions tend to do a better job of training the newbies so that certain basic mistakes tend to be avoided as each new generation of workers come through the ranks. Maybe I'm wrong. It’s possible some doctor is writing a blog post right now lamenting about the sad state of affairs in medicine and how the same sort of novice mistakes are still being made. I'm not sure.

What do you think?

Discuss this Article 5

patrickgroce
on May 30, 2012
Would it stand to reason to require newbies to get a certification? Assuming we believe that the certification teaches has value and we are will to help the new dba achieve the task.
jmh
on May 30, 2012
As one of the newbies in the field, I can tell you this is entirely true. There needs to be more focus on setting a solid base of knowledge for newbies than opening their eyes with the newest feature in the application. The more training on the core functionalities and enphasizing the importance the better chances are that the newbies will become a better master.
sjcomeau
on May 24, 2012
As database technolgy matures and settles out more (as it seems to be doing), perhaps more time and effort can be spent on training ofr good technique and system performance and less on learning the next new version or feature set. Many of the changes have been great, but there are limits to leanring new things.
JoseTorr
on Sep 27, 2012
I was lucky and got trained by an old timer dba as well as started my dba journey on DB2 for mainframe, where the dba was the only one allowed to create tables either in prod or non-prod. So this allowed us to make sure that everything that was required was there. But once I moved into sql server I received a rude awakening. Many organizations where I worked let the development teams create their own objects in non-production and production dba's would promote to production as is. Add to this that many organizations will get 3rd party software which in cases the backend is not designed with the practices and sop that you would prefer and you are unable to make any schema modifications. I just recently inherited a system that was pushed to production where 90% of the tables had no index. I think envery it organization should stand up and yell "NO INDEX ----- NO PRODUCTION"
anyoneis
on May 24, 2012
Great point! Thanks for highlighting this, as it is one of those "can't see the forest for the trees" issues. Vendors could do a great deal to solve this by coming up with "maintenance plans" which actually take real life into account, rather than just orchestrating the regular flipping and flopping of bits.

Please or Register to post comments.

IT/Dev Connections

Las Vegas
September 30th - October 4th

Paul ThurottOur Experts will show you:
• Common SQL Server
Problems
• Best Practices for T-SQL
• SQL Server Integration
Services
• Database Development

Come See Mike Otey & Tim Ford in Person!

Early Registration Now Open

From the Blogs
May 9, 2013
blog

My ISO 8601-Compliant Signature 2

My family recently just "officially" announced that we're in the process of adopting a child from South Africa. We're quite excited, of course, but there's a ton of paperwork to do—along with the need for gobs of signatures....More
May 8, 2013
blog

Use SSIS for ETL from Hadoop

In this blog post, Mark Kromer walks you through using SSIS as a way to use ETL techniques using Microsoft's Hadoop on Windows (HDInsight) as a source using Hive connectors...More
Vision road sign
May 6, 2013
blog

Cheaters Never Win, Even in TPC Benchmarks

In this portion of the series on database benchmarking, I want to tell you about one of my favorite aspects of the TPC benchmarks – CHEATING....More
SQL Server Pro Forums

Get answers to questions, share tips, and engage with the SQL Server community in our Forums.