Microsoft SQL Server sample script

The Ctrain_ModelCreate_SqlServer.sql file contains all the SQL required to create the database.

You can use Microsoft SQL Server Management Studio to run the script.

You must edit the script to meet your needs. You need to change:

  • Database names
  • Sign in and user names and passwords for the administrative users
  • FILE size setting
  • FILEGROWTH setting

When you edit the script, follow these rules.

  • The database name, the sign in name, and the user name for each database type (authorized and production) must be the same.
  • The name of the production database cannot be longer than 126 characters, and the name of the authorized database must be the production database name plus '_A.' For example, if the production database name is CTRAIN, the authorized database name must be CTRAIN_A.
  • The production and authorized databases share the filegroup used for your dimension data. This means that the additional filegroup created for the authorized database must match the name of one of the filegroups for the production database.