| |
|
|
Lesson 5
:  Verifying and configuring SQL Server.
After completing your installation, do some basic checking and configuration:
- Start the SQL Server service via one of the following: NT Service Manager, SQL Server Control Manager or SQL Server Enterprise Manager. Or, you can issue the command NET START MSSQLSERVER from a DOS prompt.
- Start up the SQL Server Query Analyser and try establishing a connection. Use the sa logon, with a blank password, or else choose Windows NT Authentication. Change the database in the drop down list at the top to pubs (the sample database provided) and run a couple of simple queries.
- Change the System Administrator password, using the Query Analyzer: sp_password NULL, 'Your Desired Password', sa
- If you have multiple versions of SQL Server installed, you'll need to configure which version is active. For instance, if you have SQL Server 6.5 installed prior to installing SQL Server 7.0, when you've finished, SQL Server 7.0 will be active. Suppose you want to go back and use SQL Server 6.5 for a while? You could issue this command:
c:\mssql7\binn\vswitch -SwitchTo 65 -Silent 1
There are many other advanced configuration options that you can set for SQL Server. You should bear in mind that you can significantly impact performance by changing these options, so in a real world environment you should never do so unless you have a good reason to.
For the exam, one notable configuration option is the "allow updates" option. By default, this option is off. If you set it on, this allows you to modify system tables directly rather than just through special system stored procedures. (More about what system tables are comes in a later tutorial). The syntax to make this change is:
sp_configure 'allow updates', '1'
reconfigure with override
However, the safest way to enable the "allow updates" option is to start SQL Server up from a command prompt using:
sqlservr -m
This starts SQL Server up in a single-user mode, with "allow updates" already on. This means that you prevent the risk of other users connecting and making changes to system objects
|