Initialize Statement

The initialize statement causes DMUTILITY to initialize all database files. If you also set the ZIP compiler control option, the WFL deck used to compile your database initiates DMUTILITY automatically. If you reset the ZIP compiler control option, you must initiate DMUTILITY manually. The initialize statement should be used only when creating a new database. It should not be present when the description of an existing database is being modified.

If you compile DASDL without using the UPDATE option and an initialize statement, DASDL responds as if you were compiling a new database and creates the following files:

  • A new description file

  • A new control file (if the DMCONTROL compiler control option is set)

  • New tailored software, for example, the DMSUPPORT library (if the ZIP compiler control option is set)

The database files are untouched. For more information about the UPDATE option, refer to UPDATE Option in Using the MODEL and UPDATE Options.

DMUTILITY is not initiated automatically if

  • The ZIP compiler control option is set.

  • The INITIALIZE statement is included in the DASDL symbol.

  • The BACKUPKEYSET is not reset.

  • DASDL contains at least one structure with STRENCRYPT set; the key set for the database must be backed up before the database is opened.

It is not necessary to initialize large object (LOB) files. However, if you do initialize a LOB file, use the AX command if you want to override the current initialized file.

The following diagram illustrates the syntax for initializing your database:

<initialize statement>

── INITIALIZE ─────────────────────────────────────────────────────────┤
Note: Do not use the initialize statement on a system that has the DMALGOLUNSAFE option set. If you do, the database files will not be initialized because of security constraints. Instead, wait until the DMSUPPORT library is created, and use the MP system command, with the EXECUTABLE option, to make the DMSUPPORT code file in an executable code file. Then use the initialize statement to initialize your database files. For more information on the DMALGOLUNSAFE option, see the Security Overview and Implementation Guide . For more information on the MP system command, see the System Commands Operations Reference Manual.

Example

Include the following initialize statement to initialize all database files:

INITIALIZE;
D DATA SET
 (
  K NUMBER (4);
 );
S SET OF D KEY K;