Upgrade SQL Server on your workstation

Lately, I’ve seen many people struggling to upgrade their workstation to the latest version of SQL Server. The main source of the problem is usually the web installer/wrapper, which can fail for a variety of reasons that aren’t always made clear by the error messages. Today, I’m going to walk through one way you can approach a workstation upgrade and avoid these web installer issues altogether. I’ll focus on SQL Server 2022, but most of the information applies to any modern major version. Most of the information applies if you’re installing a brand-new instance, too.

First, make sure you actually want to run a full-blown edition of SQL Server on your local workstation. There are other alternatives today that can lower the maintenance effort and performance burden of running an instance all the time, such as SqlLocalDB or Docker containers. If you’re on an Intel Mac, you can use Azure SQL Edge and, on M1 or newer, see Regular SQL Server on Apple Silicon? Yes you can!

If those options don’t apply to you, read on.

Get the right edition

One of the most important things is to grab the right edition. Folks already running Express try to install Evaluation or Developer Edition, then wonder where their databases went, when they actually installed a brand-new instance and left the old one still running. Check the instance you want to upgrade using SERVERPROPERTY:

If you already have the relevant ISO, or want to download Developer Edition directly, then you can skip to the next section. Otherwise, see the following table for installer resources for various editions:

Edition Download / Notes
Developer

Web installer (US English)
Other languages

Better: Direct ISO download (again, US English)

Express Web installer (US English)
Other languages
Evaluation Fill out the form here
I’m not sure if an upgrade is supported. In any case, be aware that this instance will silently start failing following the next service start after 180 days.
Standard
or
Enterprise
It’s not common to run these editions on workstations. You’ll need to get the installation media from your organization, your licensing rep, or subscriber downloads. You can also download from the link to Evaluation Edition, and enter your license key during setup.

But, look, don’t use the web installer to install SQL Server. Always download the media when presented with a choice, mount the ISO, and use setup.exe! I don’t need to step you through the web installer wizard – there are plenty of basic tutorials out there for that. I’m here to tell you to not use the wizard and to download the ISO. And keep the ISO, somewhere on the network, since you’ll likely use it again on other machines, and it will also come in handy if you ever want to add or change features.

Don’t use the web installer

If you choose to use the web installer, you may encounter the unhelpful Oops... result (which can happen in any edition):

Depending on the error message displayed below that, you can Google for the error code and possibly muck around with the registry, and maybe even get past the error. Or you can just download the ISO from the start, like I told you. 🙂 This avoids issues with the web installer, and also means you download one thing, exactly once. So instead of Basic or Custom, choose the Download Media option:

Then choose the ISO or the CAB option. I’m going to assume you’ll pick ISO because that’s what I always pick. I honestly don’t even remember what you do with a CAB file. An ISO is easy to mount from anywhere, which means you can throw it on the network or external drive and never have to download it (or copy it to your machine) again:

Open the folder and verify the ISO file is there:

I’m trying to say this in as many ways as I can, to make sure there is no misinterpretation: download the ISO; don’t use the web installer.

Slipstream updates

You typically want to make sure you’re updating to the latest cumulative update, or a specific patch level (including GDR) if you are trying to replicate something or need to match a specific environment. (I talk about CUs and GDRs here.) And you can do this without having to run two installers by “slipstreaming.” For SQL Server 2022, you can find all the publicly available updates in the Microsoft Catalog:

Clicking “Download” on the update you want will open this popup; right-click and choose the “Save link as…” option:

I generally put this into the same place I saved the ISO (in my case, D:\upgrade).

Mount the ISO

Now, right-click the ISO and choose Mount:

This will open an Explorer window with what looks like a DVD drive, and it will be labeled with a certain drive letter (in my case, H:).

Run setup.exe as an administrator

Next, open a Command Prompt as an administrator, to be sure you avoid failures running the installer with insufficient permissions:

And run the following (replacing drive letters and paths appropriately):

Now you’re right back where you would have been if you had started setup by inserting a physical CD or DVD into your computer, like we used to do back in the before times. If you just double-click setup.exe, select the “Upgrade from a previous version of SQL Server” option:

(Unless you are installing from scratch or want 2022 side by side, in which case you choose the “New SQL Server standalone” option at the top.)

In either case, you may be told you need to restart your computer. Go ahead and do that. Or, if you want to prevent that check from happening, add this to your setup command:

Next, you’ll notice that it picks up the most recent update you put in the /updatesource folder:

Pick the right instance on the “Select Instance” screen, and it should be smooth sailing from there. You’ll have to repeat from the setup.exe step for any other instances you want to upgrade to the same version.

Conclusion

Getting SQL Server upgraded (or installed from scratch) on your workstation can be a challenge, especially if you rely on the web installer. Don’t do that! At most you should use the web installer as a vehicle to download the ISO, and that’s it. Happy installing!