Creates a new databank.
A new databank is created, i.e. a physical file is created in the host file system and formatted for use as a Mimer SQL databank. The initial file size is the number of Mimer SQL pages (2K in size) specified by the integer parameter. A value of 1000 Mimer SQL pages is assumed if an initial file size is not specified.
The filename-string specifies the name of the new databank file in the host file system and this is stored in the data dictionary as the location of the databank file. If a file name is not specified, it will be the same as databank-name (and the databank will be created in the database home directory).
The databank is created with the transaction and logging options as specified:
Set operations (DELETE, UPDATE and INSERT on several rows) which are interrupted, will not be rolled back. All secondary indexes created in the databank are flagged as "not consistent". A secondary index that is flagged as "not consistent" will not offer optimal performance when used in a query, see UPDATE STATISTICS for information on how to ensure that secondary indexes are consistent.
CREATE DATABANK requires that the current ident has DATABANK privilege.
The databank name must not be the same as that of an existing databank or shadow.
The databank must be created with either the TRANS or LOG option if any of the following are true:
- the databank is to be shadowed
- the databank will be used to store tables defined with foreign or unique keys
- the databank will be used to store tables that are referenced in a foreign key context
- the databank will be used to store tables holding UNIQUE indexes
- the databank will be used to store tables on which triggers have been created
- the databank contains tables that will accept updates in their primary key column(s)
The creator of the databank is granted TABLE privilege on the new databank, with the WITH GRANT OPTION.
The value of filename-string must always be enclosed in string delimiters. The maximum length of the filename string is 256 characters.
Refer to Specifying the Location of User Databanks for details concerning the specification of path name components in filename-string.
MIMER EXTENSION The CREATE DATABANK statement is a Mimer SQL extension.
Upright Database Technology AB
Voice: +46 18 780 92 00
Fax: +46 18 780 92 40