## db_create

### Use

You create a new database instance on a local or remote computer and create the first Database Manager operator with all authorizations for managing this database instance. The operator can carry out administrative tasks for the database instance and create further Database Manager operators and database users.

At the same time you define the database system administrator.

You can enter options to define which of the versions of database software available on the database computer should be used to create this database instance, and to determine further properties of this database instance.

After the new database instance has been created, the first DBM operator and the database system administrator are initially the only users who can access the database instance.

You need to complete further steps before you can start working with the newly created database instance.

See also:

Database Administration Tutorial, Creating and Configuring a Database Instance

Concepts of the Database System, Creating and Configuring a Database Instance

### Prerequisites

You are logged on as the operating system user to the computer on which the database instance is being created (see: user_system).

To create a database instance on UNIX/Linux, you must be logged on as operating system user root, or as a member of the sdba operating system user group (see Special Operating System Users and User Groups (UNIX/Linux)).

- To create a database instance on a remote server running Microsoft Windows, you must also have administrator authorizations for the database server and the log on as batch job authorization. For information about administrating operating system users, see your operating system documentation.

The X Server has been started.
If the database software has been installed under Microsoft Windows, the system sets the Startup Type for the X Server to Automatic, so it is automatically started by the system when the computer is started. Under UNIX, you need to explicitly start the X Server of the remote database computer to be able to administer a database instance on this computer (see: Utilities documentation: Starting the X-Server).

### Syntax

db_create [-a|-auto] [-g <group>] [-u] <database_name> <dbm_user>,<dbm_user_password> [<os_user>,<os_user_password>]

Options

Option | Description
-a | -auto | Under Microsoft Windows the service entry Start-up-type for the database service in the Control Panel is set to automatic. Under the UNIX operating system this parameter is ignored.
-g <group> | For UNIX only: You assign your database files to an operating system user group other than the standard group and can thus protect the files from unauthorized access.
-u | Operating system user specification with option –u (only for Microsoft Windows): The service for starting the database kernel should run under the operating system user specified at the end of the DBM command.
<os_user> | Name of the operating system user for the remote computer If you want to create the database instance on a remote server, you must also specify the operating system user for this server. If the logon to the operating system fails, the database instance cannot be installed.
<os_user_password> | Password of the operating system user
<database_name> | Name of the database instance Note the Conventions for Database Names. The database system automatically converts the database name into upper-case letters.
<dbm_operator> | Database Manager Operator (DBM Operator) See Conventions for User Names and Passwords. The database system automatically converts the user name into upper-case letters.
<dbm_operator_password> | Password of the Database Manager operator. The database system automatically converts the password into upper-case letters.

### Reply

OK

In the event of errors, see Reply Format.

### Examples

Call the Database Manager CLI, create a local database instance with the name DEMODB, define the first Database Manager operator with the name DBM and password DBM:
>dbmcli db_create DEMODB DBM,DBM

OK

>

Call the Database Manager CLI, create a local database instance with the name DEMODB using the software stored under C:\Program Files\SDB\7600, define the DBM operator DBM with the password DBM:

>dbmcli -R "C:\Program Files\SDB\7600" db_create DEMODB DBM,DBM

OK

>

Call the Database Manager CLI, create a database instance with the name DEMODB on the remote server GENUA, define the DBM operator DBM with the password DBM, log on as operating system user ANNA with the password BLACK to the remote server:
>dbmcli –n GENUA db_create DEMODB DBM,DBM ANNA,BLACK

OK

>