Create a CM4D Site Database

The scripts needed to create (or upgrade) a SQL Server database are included with the CM4D Installation. Browse to the Database Scripts\SQLServer folder in your CM4D install directory.

1.     Right-click on Databases in the tree.

2.     Select New Database from the context menu.

a.     In the New Database dialog:

i.        On the General page:

(1)  Enter a Database name (e.g., Site).

(2)  Set the Initial Size of the Rows Data file to 50 (MB).

ii.      Go to the Options page.

(1)  Set the Recovery Model to 'Simple'.

b.     Click OK.

3.     Next, you will need to run the Create scripts for the Site database.

4.     Site Tables are always created first.

5.     Click the open file button ().

a.     Browse to the scripts for the Schema version that corresponds to the version of CM4D that you are running. By default, these files are located here: C:\Program Files\Applied Tech Systems\CM4D\Database Scripts

b.     Select Site Tables.sql.

c.      Click Open.

6.     In the use line of the script:

a.     Delete the two hypens (--) at the beginning of the line.

b.     Change [Your Site DB] to the name of the database you are running the scripts on.

c.      As you type in the name, a list of databases will appear, allowing you to select your database name.

7.     Once you have the correct database name entered between the brackets, select the Execute button.

8.     Check the Messages section for any errors.

a.     If the scripts execute successfully, go to the next step.

b.     If the scripts return errors, investigate the issue(s).

9.     Repeat the previous steps for the Site Procedures.sql, Site Indexes.sql, and Site Grant.sql scripts.

10.  Once the Site database scripts have been run successfully, continue on to the next section to create the CM4D Databases that will be managed by the Site database you just created.

See also, Create a SQL Authentication User.