Creates a new schema.
A new schema is created with the name specified in
schema-nameis specified, the schema is created with that name, otherwise the name of the schema will be the same as
ident-nameis specified, the schema and all the other objects created by the
CREATE SCHEMAstatement are created with the named ident as the effective current ident.
GRANTstatement that is specified using the normal syntax for such a statement and which is executed by the
CREATE SCHEMAstatement in the normal way.
create-table-statement, see CREATE TABLE.
create-view-statement, see CREATE VIEW.
create-index-statement, see CREATE INDEX.
create-domain-statement, see CREATE DOMAIN.
create-sequence-statement, see CREATE SEQUENCE.
create-synonym-statement, see CREATE SYNONYM.
grant-statement, see GRANT ACCESS PRIVILEGE or GRANT OBJECT PRIVILEGE.
The schema name must not be the same as that of a schema which already exists in the database.
CREATE SCHEMArequires that the current ident has
The value for
ident-nameis currently restricted to be the name of the current ident.
grant-statementis restricted to
GRANT ACCESS PRIVILEGE,
GRANT USAGE ON DOMAINor
GRANT USAGE ON SEQUENCE(i.e. it is only possible to grant privileges on private database objects).
CREATEstatement where the name of the object to be created is specified in its fully qualified form (i.e.
schema-namecomponent must be the same as the name of the schema being created by the
CREATEstatement where the name of the object to be created is specified in an unqualified form, it will be created in the schema created by the
CREATE SCHEMAstatement (and not the schema with the same name as the current ident as is usual for
It is possible for one
schema-elementto reference the objects created by other
schema-element's regardless of the order of creation of the objects. All object references are verified at the conclusion of the
CREATE SCHEMAstatement when all the
schema-element's have been executed and all objects have been created.
ExampleCREATE SCHEMA mimer_store_music;
For more information, see the Mimer SQL User's Manual, Creating Idents and Schemas.
SQL-2003 Core Fully compliant. SQL-2003 Features outside core Feature F691, "Collations and translations" support for CREATE COLLATION statement in schema definition.Feature F251, "Domain support" support for CREATE DOMAIN statement in schema definition.Feature F171, "Multiple schemas per user" support for schema name-clause. Mimer SQL extension Support for CREATE INDEX, CREATE SEQUENCE and CREATE SYNONYM statements in a schema definition is a Mimer SQL extension.
Mimer Information Technology AB
Voice: +46 18 780 92 00
Fax: +46 18 780 92 40