Adventureworks database installation in sql server 2014

Adventureworks database is sample database sql server. Until 2012, Microsoft provided sample databases are in the format of mdf and ldf file downloads, we have to download and attach the mdf and ldf file to install Adventure works 2008/2008 R2/2012. This has changed completely in 2014. Download Adventureworks database from codeplex site.

Adventureworks database installation in sql server 2014:

1. Download from codeplexe site.

2. Extract the zip file.

3. Copy the file AdventureWorks2014.bak to ‘C:\Program Files\Microsoft SQL Server\MSSQL12.MSSQLSERVER\MSSQL\Backup\

4. Open SQL Server Studio Management console and execute the following script to create AdventureWorks2014.

RESTORE DATABASE AdventureWorks2014
FROM disk= 'C:\Program Files\Microsoft SQL Server\MSSQL12.PRD1\MSSQL\Backup\AdventureWorks2014.bak'
WITH MOVE 'AdventureWorks2014_data'
TO 'C:\Program Files\Microsoft SQL Server\MSSQL12.PRD1\MSSQL\DATA\AdventureWorks2014.mdf',
MOVE 'AdventureWorks2014_Log'
TO 'C:\Program Files\Microsoft SQL Server\MSSQL12.PRD1\MSSQL\DATA\AdventureWorks2014.ldf'

5. Now refresh the database.
Adventureworks database installation in sql server

Related Posts

Responses are currently closed, but you can trackback from your own site.

Comments are closed.

Powered by k2schools