CreateDatabase
Synopsis
[Actions] CreateDatabase:Name=DatabaseName,Directory=DatabaseDirectory[,Additional Properties]
Description
CreateDatabase defines a database. InterSystems IRIS® creates that database when processing the [Actions] section during a configuration merge.
You can specify any possible database properties in the CreateDatabase definition. During the merge, InterSystems IRIS runs SYS.Database.CreateDatabase()Opens in a new tab to create the database defined by CreateDatabase. Only the Name and Directory properties are required; the complete list of properties is available in the class reference.
When using CreateDatabase on an ECP client to add a remote database, there are two unique required properties. These are:
-
Server – This specifies the name of the ECP server where the remote database is located.
-
LogicalOnly (1 or 0) – When set to 1, this prevents CreateDatabase from creating a physical database on the ECP client.
The section below contains an example of using these properties to add a remote database.
Example
Upon running a configuration merge, the following example creates the Customers database, specifying the initial size and maximum size:
[Actions] CreateDatabase:Name=Customers,Directory=/IRIS/mgr/Customers,Size=5368,MaxSize=536871
If the Customers database is a remote database located on Node1, the [Actions] section would instead look like:
[Actions] CreateDatabase:Name=Customers,Directory=/IRIS/mgr/Customers,Server=Node1,LogicalOnly=1
Changing This Operation
This operation is designed to be used during a configuration merge. You can change CreateDatabase by editing the merge file in a text editor (as described in Editing the Active CPF).
For information about creating and editing a database from the Management Portal, see Configuring Databases.