NonStop SQL/MP Reference Manual

Table Of Contents
NonStop SQL/MP Reference Manual142115
C-129
Examples—CREATE CATALOG
especially important for tables with many partitions. The performance of DDL
statements such as CREATE TABLE, ALTER TABLE ADD PARTITION, and
DROP TABLE can be greatly enhanced with an effective cache setting.
For example, a table with 200 partitions, all described in a single catalog, has 40,000
rows in the PARTNS catalog table and in the IXPART01 index on the PARTNS
catalog table. Creating such a table causes more than 80,000 writes to the catalog.
Using the default cache value can cause the operation to take up to 25 times longer
than if you set disk cache to 4 MB.
For information about managing cache, see the NonStop SQL/MP Installation and
Management Guide. For information about PUP, see the Peripheral Utility Program
(PUP) Reference Manual.
If ServerWare SMF is installed on your node, there are two ways to place the set of
catalog tables on a single physical volume:
°
specify a direct subvolume for catalog
°
specify a virtual volume and subvolume for catalog and a physical volume
that belongs to the virtual volume in PHYSVOL
If you specify a virtual volume for catalog and omit the PHYSVOL option, SQL
can distribute catalog tables among multiple physical volumes in the virtual volume.
Mixed-version systems
The version number of a new catalog is the version of NonStop SQL/MP on the
node where the catalog resides, even if you create the catalog from a node with a
different version number.
For example, if you issue CREATE CATALOG from a version 315 node but specify
a catalog subvolume on a version 1 node, the new catalog is a version 1 catalog.
Examples—CREATE CATALOG
The following statement creates a catalog named PERSNL on node \SYS1 and
volume $VOL1, with security “nunu”:
CREATE CATALOG \SYS1.$VOL1.PERSNL SECURE "nunu";
The following SQLCI example uses ALTER DEFINE to set the CATALOG attribute
of the =_DEFAULTS DEFINE before creating a catalog. The new catalog is created
on \SYS1.$VOL.SALES.
ALTER DEFINE =_DEFAULTS, CATALOG \SYS1.$VOL.SALES;
CREATE CATALOG;