Create the OESQLDemo SQL Server Database

Provides instructions for using Microsoft SQL Server Management Studio to create a SQL Server database to use in this tutorial, and to create the required schemas and tables.

We provide an SQL script that you can run to create the OESQLDemo SQL Server database and automatically create its schemas and tables. To access and run the script:

  1. Go to CreateAndLoadOESQLDemo.txt.
  2. Using your browser's Save As feature, save this as a flat text file on a local drive. Name the file CreateAndLoadOESQLDemo.sql.
    Note: If your browser adds any extraneous text to the script file, edit the file to remove the extraneous text.
  3. Start the Microsoft SQL Server Management Studio.
  4. Connect to the server where you want to create your database.
    Note: The user ID and password you provide must log you on to SQL Server with dbadmin or sysadmin permissions that enable you to create a SQL Server database.
  5. Open and execute CreateAndLoadOESQLDemo.sql.

    This SQL script creates a SQL Server database named OESQLDemo, and creates the schemas and tables required to complete the OpenESQL Assistant tutorials.

  6. Close SQL Server Management Studio.
Note: As an alternative, you can create the SQL Server database from the command line as follows:
  1. At a command prompt, change to the directory where you saved the CreateAndLoadOESQLDemo.sql file.
  2. Enter:

    sqlcmd -S . -E -i CreateAndLoadOESQLDemo.sql