SqlServerManager
First of all, I must tell you that the download pages at Microsoft changes often, and so do versions. You might not find the same pages as I show here below, but I'm confident that you will be able to download Ms SQL Server express Make sure you select a version suitable for your system and that contains the tools! You can see that it contains the tools if the filename contains 'wt' or if the link contains 'with tools' or something similar. This will add Ms SQL Server Manager. If you missed that, you can always download the Manager separatly.You might be prompted for a Microsoft account, and if you do not have one, my recommendation is that you register for one.
Make sure to select a file suitable for your use. You need to select 32 or 64 bits. If you have a 32 bit operating system you must select a 32 bit version. Also make sure to select a file that has the tools:
Installation instructions
When download is finished, start the installation. The first thing you see is the SQL Server Installation Center. It is not just an installation program, but rather a maintenance tool for your SQL server. It will be available after installation if you need to change anything, or do some maintenance. At the end of this page I have supplied a screenshot of the start menu, and you can see that it is present among lots of other tools.Note the left-hand menu. It starts with 'Planning', but 'Installation' is already selected, because that is what you normally would want to do now.
The main part has two links, one for installation, and one for upgrade. You can have different versions installed at the same time, so if you already have an older version that you want to keep, you must select to install, like if you do not have any version at all. If you have a version that can be upgraded, you might want to do that. It is up to you. For now, I will do a new installation so I click on the first link:
There is a common error in the installation procedure, the 'Restart computer failed' problem. If you run into that, just take a look at the bottom of this page for the solution.
As usual, you have to accept the license terms:
The features are pre-selected for most standard installations, and I do not think you would want to change that now. It is possible to make changes later, if you like.
When we come to instances you have an interesting choice to make. Will you be using more than one SQL Server on your computer? Is there a reason to do that? Yes, if you have another version that you want to keep, you can do that by installing all instances of SQL Server as named instances. This means that you will have to use you computer name (or IP, URL or localhost) and a name for the SQL server. If you select 'Default instance' you will address the SQL Server by your computer's name only (or IP, URL or localhost). You can, of course, only have one default instance on a computer. I have choosen named instance, since I have an older version that I like to keep, and I see no reason to make this new instance the default one. You can do as you like.
Next step is to configure the server. Again, the default settings ar normally ok. SQL Server uses a separate account for some activities that is not suitable to let the loged-on user account handle. Such an account we normally call a service account because they are the once under which services are running. In this case that would be the services SQL Server services. Leave that as is.
If you have some specific need for collation order, that is how strings shoud be sorted, you may want to take a look at the Collation tab. It has been pre-set from your computer's language and regional settings, and should be ok for you. Do not change that unless you are shure that you know what you are doing. There are a lot of different character sets, and SQL Server needs to know which one is valid for the data you want to put into the database. If you want to store text containing national characters, you know, those that has little dots, rings, accents above or hooks and stuff below, it is crucial that the SQL Server knows about them in order to sort strings correctly.
If you pressed the Customize button, you will open a form with lots of different character sets and the option to let Windows or SQL Server do the collation. As I mentioned before, don't change this unless you are absolutly certain you know what you ar doing.
Now it is time to configure the database engine. There are four tabs.
- Server configuration. Here you select authentication mode.
- Data directories. This is where the datbase stores data and logs. You can open the tab in order to see where the data files are stored, but you do not need to change it for this course. If you have more than one version of Ms SQL Server installed, you will see that the data and log files are stored in separate folders for the different versions.
- User instances. Here you can elect to have more than one instance of this database engine. Also not needed for this course.
- Filestream. This is for the option to add streaming functionality to the database. We will not need this.
Now you can sit back and wait for the installation to finish.
Hopefully it will all end with this report. Just close it, and also close SQL Server Insallation Center, that's where we started the installation.
If you take a look at the start menu, you can see that there was quite a few items installed. You might use the Configuration Manager or the SQL Server Insallation Center, but the tool you will be using most is the SQL Server Management Studio.
Error: Restart computer failed!
There is a common problem when installing probgams, and especially when installing Ms SQL Server. It is not very serious, but I will spare you the trouble of Googling for the solution by giving it to you here. This is what it looks like when you have the problem:The problem is that some installations needs to use a registry key in order to do stuff when restarting the computer after some installation. The problem with that is that the key might contain invalid data after a failed installation or after deleting a program rather than uninstalling it. Then the key will not be deleted, because the program that should delete it is not going to run when you restart your computer. You can try restarting it as many times as you want, it will not help.
What helps, however, is to manually delete the content of the key. Just run the registry editor (regedit.exe). You can start it by opening the start menu and type in 'regedit'. Then navigate to the key you see in this picture, doubleclick it, and erase it's content: