/*============================================================================
  File:     1_CreateBaselineDB.sql

  Summary:  This script creates a data that can
			be used to hold baseline data captured
			from SQL Server.
			Alter file location as appropriate.

  Date:     April 2015

  SQL Server Version: 2005/2008/2008R2/2012/2014
------------------------------------------------------------------------------
  Written by Erin Stellato, SQLskills.com

  (c) 2015, SQLskills.com. All rights reserved.

  For more scripts and sample code, check out 
    http://www.SQLskills.com

  You may alter this code for your own *non-commercial* purposes. You may
  republish altered code as long as you include this copyright and give due
  credit, but you must obtain prior permission before blogging this code.
  
  THIS CODE AND INFORMATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF 
  ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED 
  TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
  PARTICULAR PURPOSE.
============================================================================*/
USE [master];
GO

/*
	Create a database to hold baseline information
*/
CREATE DATABASE [BaselineData]
 ON  PRIMARY ( 
	NAME = N'BaselineData', FILENAME = N'C:\Databases\BaselineData\BaselineData.mdf' , SIZE = 1048576KB , FILEGROWTH = 524288KB 
	)
 LOG ON ( 
	NAME = N'BaselineData_log', FILENAME = N'C:\Databases\BaselineData\BaselineData_log.ldf' , SIZE = 524288KB , FILEGROWTH = 262144KB 
	);
GO

ALTER DATABASE [BaselineData] SET RECOVERY SIMPLE;
GO



--load

bulk insert baselinedata.dbo.SQLskills_waitstats
fROM 'C:\SQLskills\ws.txt'
with
( datafiletype = 'native',
tablock)