SQL SERVER – Installing AdventureWorks for SQL Server 2011

Posted by pinaldave on SQL Authority See other posts from SQL Authority or by pinaldave
Published on Wed, 08 Dec 2010 01:30:26 +0000 Indexed on 2010/12/08 5:44 UTC
Read the original article Hit count: 1218

I just began with SQL Server 2011 Denali CTP1. The very first thing, I realized that there is no AdventureWorks Sample Database available for Denali. I quickly searched online and reached to Microsoft documentations where it provides information of the how to install (restore) AdventureWorks for SQL Server 2011 for Denali.

  1. Download the AdventureWorks from here.
  2. Run following script (replace your path of mdf file.

CREATE DATABASE AdventureWorks2008R2
ON (FILENAME = 'C:\SQL 11 CTP1\CTP1\AdventureWorks2008R2_Data.mdf')
FOR ATTACH_REBUILD_LOG ;

When you run above script it will give you following message and you are DONE!

File activation failure. The physical file name "C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\AdventureWorks2008R2_Log.ldf" may be incorrect.
New log file 'C:\SQL 11 CTP1\CTP1\AdventureWorks2008R2_log.ldf' was created.
Converting database 'AdventureWorks2008R2' from version 679 to the current version 684.
Database 'AdventureWorks2008R2' running the upgrade step from version 679 to version 680.
Database 'AdventureWorks2008R2' running the upgrade step from version 680 to version 681.
Database 'AdventureWorks2008R2' running the upgrade step from version 681 to version 682.
Database 'AdventureWorks2008R2' running the upgrade step from version 682 to version 683.
Database 'AdventureWorks2008R2' running the upgrade step from version 683 to version 684.

I will soon write my experience about Denali. However, SQL Server Management Studio more started to look a like Visual Studio.

Reference: Pinal Dave (http://blog.sqlauthority.com)


Filed under: Pinal Dave, SQL, SQL Authority, SQL Backup and Restore, SQL Query, SQL Scripts, SQL Server, SQL Server Management Studio, SQL Tips and Tricks, T SQL, Technology

© SQL Authority or respective owner

Related posts about Pinal Dave

Related posts about sql