Trevian
Introduction
Course: PT2520
Week: 1
Lab: Installing SQL Server 2008
Assignment
The purpose of this lab is to familiarize you with the procedure involved in initial installation of
Microsoft SQL Server.
Story
A key requirement of modern information technology (IT) infrastructure is secure and timely access to
and storage of vital data. The most reliable, time-tested method of storing electronic data is inside a
database. A database is a collection of information that's related to a particular function or purpose. In
its simplest form, your contact information kept in a file on your computer hard disk is a database. Banks
have databases on customers and financial transactions. E-business sites use databases to track orders
and inventory. Telecom operators use databases to keep track of accounting and subscriber
information.
DBA refers to the Database Administrator. DBAs are those professionals who organize information in a
meaningful way so it can be easily maintained, retrieved, and updated. DBAs ensure that data produces
and delivers real business value. The role of the database administrator is very important in an
organization.
A critical duty of the DBA is designing databases for maximal performance, scalability, flexibility, and
reliability. A well-designed and implemented database justifies the database investment. In this regard,
the DBA is responsible for installing a new database management system (DBMS) and upgrading existing
DBMS. This course uses Microsoft SQL Server 2008 as the DBMS. This lab will familiarize you with the
installation steps and how to get started on SQL Server 2008.
Conditions
There are no conditions for this lab.
Notes
The lab does not reflect the real-world environment. It only familiarizes you with the steps involved in
installation of software.
As you perform the various steps of the lab, update your lab report. You will send the lab report to your
online instructor for evaluation after you quit the lab.
Submit the following three screenshots to your online instructor for evaluation:
1) A screenshot showing the successful installation of SQL Server 2008
2) A screenshot of the Object Explorer panel showing the AdventureWorks2008R2 database file path
3) A screenshot of the updated row in the AdventureWorks2008R2 database table
These screenshots map to the evaluation criteria given below. Therefore, submit all screenshots to
receivepoints for all evaluation criteria.
Diagram
Connecting to your lab
In this module you will be working on the following equipment to carry out the steps defined in each
exercise.
PLABSQLBUILD
Each exercise will detail which console you are required to work on to carry out the steps.
To start simply click on the named Server from the device list (located on the left hand side of the
screen) and click the Power on from the in tools bar. In some cases the devices may power on
automatically.
During the boot up process an activity indicator will be displayed in the name tab:
Black - Powered Off
Orange - Working on your request
Green - Ready to access
If the remote console is not displayed automatically in the main window (or popup) click the Connect
icon located in the tools bar to start your session.
If the remote console does not appear please try the following option:
Switch between the HTML 5 and Java client versions in the tools bar.
In the event this does not resolve your connectivity problems please visit our Help / Support pages for
additional resolution options.
Sample Solution
Task Index
Task 1
Install SQL Server 2008 R2.
Task 2
Install AdventureWorks2008R2 Sample Database.
Task 3
Tour SQL Server Management Studio (SSMS).
Task 1 - Install SQL Server 2008 Standard
Step 1: Create a SQL Server Service account
Action:
1) Click Start, go to Administrative Tools > Active Directory Users and Computers and expand
PRACTICELABS.COM.
2) Right-click on Users and choose New > User.
3) Use the following properties for the new user account. First name: SQL, Last name: SA, Logon name:
SQLSA, click Next and in the Password page insert Pa$$w0rd both in the Password and Confirm
Password fields, Clear User must change password at next logon box. Click Finish to complete the
creation of the new user account.
4) Close Active Directory Users and Computers.
Step 2: Begin installation.
Action:
1) Double-click the SQL_Server_Setup.exe file located on the desktop.
2) The SQL Server Installation Center Window displays the installation steps. Click New installation or
add features to an existing installation link.
3) On the License Terms screen, click I accept the license terms check box and click Next.
Step 3: Select features.
Action:
1) From Feature Selection page, accept the default selections. Click Next. The Installation Rules screen is
displayed.
Step 4: Select default instance.
Action:
1) On the Instance Configuration screen, ensure that Default Instance is selected. Click Next. The Disk
Space Requirements screen is displayed.
Step 5: Verify server configuration
Action:
1) From Server Configuration page, go to SQL Server Database Engine Service. On the Account Name
column, click drop-down list and choose Browse… From Select User, Group box, type SQLSA and click
Check Names and then OK.
2) The PRACTICELABS\SQL SA is now an account assigned to SQL Server Database Engine Service. Click
in Password box and type Pa$$w0rd
3) Go to SQL Server Reporting Services. On the Account Name column, click drop-down list and choose
Browse… From Select User, Group box, type SQLSA and click Check Names and then OK.
4) The PRACTICELABS\SQL SA is now an account assigned to SQL Server Reporting Services. Click in
Password box and type Pa$$w0rd.
5) Click Next.
Step 6: Database Engine Configuration
Action:
1) Click Next.
Step 7: Select Reporting Services option
Action:
1) Click Next on the Reporting Services screen. The Installation Rules screen is displayed, choose Next.
From the Error Reporting page, choose Next.
Step 8: Configure installation configuration rules
Action:
1) Click Next to keep the default configuration.
Step 9: Complete installation
Action:
1) Verify that installation is complete.
Take a screenshot showing the successful installation of SQL Server 2008 R2.
Click Close.
2) Close the SQL Server Installation Centre.
Task 2 - Install AdventureWorks Sample Database
NOTE: The AdventureWorks2008R2 Sample Database will prepare SQL Server 2008 R2 with the data to
perform Task 3.
Step 1: Copy the .MDF and .LDF files to the Data folder
Action:
1) Open Windows Explorer by going to Start menu and click on Computer. Double click on the C:\ drive and then AdventureWorks2008R2_Database folder. Verify that AdventureWorks2008R2 database and AdventureWorks2008R2 transaction log are available.
2) Copy the AdventureWorks2008R2_Data.mdf and AdventureWorks2008R2_log.LDF files then paste
the files in C:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA path.
Close Windows Explorer.
Result:
Begin installation of AdventureWorksLT2008_Only_Database.
Step 2: Attach the sample databases to SQL Server Management Studio
Action:
1) Click Start, go to All Programs > Microsoft SQL Server 2008R2 > SQL Server Management Studio.
2) From Connect to Server log on screen, in Server Name box type PLABSQLBUILD. Click Connect.
3) From SQL Management Studio, expand PLABSQLBUILD and then right-click on Databases. Choose
Attach Database.
4) From Attach Database dialogue box, click Add…
5) From Locate Database Files – PLABSQLBUILD box, go to C:\Program Files\Microsoft SQL
Server\MSSQL10_50.MSSQLSERVER\MSSQL\DATA\AdventureWorks2008R2_Data.mdf. Click OK when
the file is selected.
6) From Attach, the AdventureWorks2008R2 database and logs are now attached. Click OK.
Step 3: Verify the AdventureWorks Database
Action:
1) From SQL Server Management Studio, expand Databases folder and verify that
AdventureWorks2008R2 is successfully attached. Keep SQL Server Management Studio running.
Task 3 - Tour SQL Server Management Studio (SSMS)
Step 1: Access SQL Server Management Studio
Action:
1) From SQL Server Management Studio, right-click AdventureWorksLT2008R2 and choose Properties.
2) On Database Properties-AdventureWorksLT2008R2 dialogue box, click on Files page. Go to Owner
text box and click on … button.
3) On Select Database Owner box, click on Browse…
4) On Browse for Object, select PRACTICELABS\administrator and PRACTICELABS\SQLSA. Click OK
twice.
5) Back in SQL Server Management Studio, click on View and choose Object Explorer Details.
Result:
Management Studio presents information in two windows:
The Object Explorer (left window) is a tree view of all the database objects in a server.
The Document Window (right window) can contain query editors and browser windows. By default, the
Summary page is displayed and is connected to the instance of Database Engine on the current
computer.
Step 2: Access the AdventureWorksLTdatabase.
Action:
1) In the Object Explorer, expand Databases>AdventureWorksLT2008>Tables.
Result:
Once expanded, you will notice that the database contains a number of objects. Under Tables, you see a
list of all the tables defined for the database.
Step 3: Access an existing database table.
Action:
1) Right-click the Person. Person table and choose Select Top 1000 Rows.
Result:
The result displays several windows within the document window area:
The middle window contains two panes. The top pane contains the SQL Script and the bottom pane
contains the results of the SQL Script execution.
The right window contains the properties for the SQL Script execution.
Action:
1) Right-click the Person. Person table and select Edit Top 200 Rows.
Result:
The result displays different windows within the document window area:
The middle window contains an editable grid of the table rows and columns.
The right window contains the properties for the SQL Script execution.
Step 4: Update an existing row.
Action:
1) Click inside the editable grid and change one of the values for an existing row.
2) Change the title of Customer ID 2: to Mr. Terri Lee Duffy.
3) Click on the Title cell to add the Mr. to the field.
Result:
Notice that there is a red exclamation-point icon associated with the changed column.
Step 5: Verify the change.
Action:
1) Click on another row within the grid.
2) Take a screenshot of the updated row in the AdventureWorks2008R2 database table.
Result:
Notice that the red exclamation icon disappears. This indicates that the row has been updated into the
database table.
Step 6: Exit the database.
Action:
1) Select File>Exit from the menu to close SQL Server Management Studio.
Result:
SQL Server Management Studio is closed.
Summary
In this lab you completed the following tasks:
Task 1 - Install SQL Server 2008 Standard.
Task 2 - Install AdventureWorks Sample Database.
Task 3 - Tour SQL Server Management Studio (SSMS).