SQL/MX 3.2 Management Manual (H06.25+, J06.14+)

Table Of Contents
When NonStop SQL/MX is installed and initialized on a node, the system catalog,
NONSTOP_SQLMX_nodename, and its schemas are automatically created. These metadata schemas
are:
SYSTEM_SCHEMA schema, which contains the five system schema tables used for catalog
reference and recording catalog and schema information.
SYSTEM_DEFAULTS_SCHEMA schema, which contains the default settings for options and
other attributes used with MXCI commands and SQL/MX statements.
MXCS_SCHEMA schema, which contains the metadata information needed by MXCS.
SYSTEM_SQLJ_SCHEMA, which contains the stored procedures VALIDATEROUTINE and
VALIDATEROUTINE2.
DEFINITION_SCHEMA_VERSION_version schema, which contains the definition schema
tables used to maintain information about SQL/MX objects. A set of these tables is created
specifically for the system catalog.
SYSTEM_SECURITY_SCHEMA, which contains dedicated tables to support system administrators
and other security-related features.
A set of definition schema tables is also created for each user catalog when you create the first
schema for that catalog. As you add more schemas and objects to the catalog, these definition
schema tables are updated to describe them.
You can use SELECT to view the contents of SQL/MX metadata tables, but only the super ID user
can modify their content. For example, only the super ID user can perform ALTER, DROP, DELETE,
INSERT or UPDATE statements on metadata tables.
For more information, see the SQL/MX Reference Manual.
Creating Catalogs
You begin building your SQL/MX database by creating user catalogs. A catalog:
Is the named logical object that contains descriptions of a set of schemas.
Is owned by the authorization ID that creates the catalog, but this authorization ID has no
special capabilities other than the ability to register or unregister the catalog.
Can contain multiple schemas, each of which can be owned by a different user.
Cannot contain any other catalogs.
Catalog Naming
The catalog name is an SQL identifier that represents the first part of the three-part ANSI logical
name of the form catalog.schema.name. The catalog’s SQL identifier must be unique among
catalogs on the node.
It is permissible for two nodes (for example, nodes \A and \B) in a distributed SQL/MX environment
to have catalogs with the same name. Each node can access its own catalog and the objects in it
by using location-independent ANSI names. However, node \A cannot access anything in the
same-named catalog on node \B, and vice versa. For this reason, it may be best to avoid naming
a catalog with the same name used by a catalog on another node. If you intend to register the
remote catalog from either node, do not use the same catalog names.
For more information, see the SQL/MX Reference Manual.
Rules for Creating and Dropping Catalogs
Any user on a node can create a catalog on that node.
Any user on a node can drop an empty catalog.
76 Creating an SQL/MX Database