Wizards are evil – wait, no they aren’t!

SQL Server contains many “Wizards. Wizards are simply programs that collect information based on user choices. The Wizard’s screens explain each step and the choices on that screen. Based on those answers collected from the user, the Wizard performs some task. What could possibly be wrong with helping a user this way? Well, plenty.

Wizards hide complexity from the user, which can prevent them from learning the process behind the Wizard. Wizards can also enable the user to choose the wrong options too easily – especially if the user doesn’t read the screens.

For instance – in the example that’s always mentioned, the Maintenance Wizard, the screens present not only “Shrink Database” (which you should never do) but it presents both REBUILD and REORGANIZE options for the Indexes. Of course, Microsoft isn’t sure which you need to do, but some users select both – which isn’t necessary.

And then from time to time there’s a bug in the code and the Maintenance Wizard doesn’t work properly. For this reason, some experts have recommended that we remove all of the Wizards.

But I don’t agree. I think Wizards have their place – given two conditions. Number one, they always need to work. And number two, the users need to read the options carefully so that they make the right choices. The Wizards do a good job of making sure the process can be scripted, and many of them drop you off (like the Maintenance Wizard) with a package that can be changed later. So don’t give up on the Wizards. Let’s fix them. In fact, tomorrow I’ll talk about an idea brewing in my head, and it involves actually increases the number of Wizards!

Comments (2)

  1. mjswart says:

    I’ll grant you that some wizards aren’t evil. But there are certainly wizards with a huge spectrum of usefulness. Think about it. I think the point you make is that some wizards are very useful. (think Gandalf or Dumbledore) While others are umm… less than useful (think Orko or the Wizard of Oz).

  2. NULLgarity says:

    The best wizards give the user the ability to spit out the actual code at the end.  That’s one of the things I’ve always appreciated about SSMS (even if I don’t always appreciate all of the code it generates).