SQL/MX 3.x Reference Manual (H06.22+, J06.11+)

SQL/MX Statements
HP NonStop SQL/MX Reference Manual640322-001
2-86
Syntax Description of CREATE TABLE
A table can have an unlimited number of referential constraints, and you can
specify the same foreign key in more than one referential constraint, but you must
define each referential constraint separately. You cannot create self-referencing
foreign key constraints.
Publish/Subscribe's embedded update and embedded delete statements are not
allowed on tables with referential integrity constraints:
STORE BY store-option
specifies a set of columns on which to base the clustering key. The clustering key
determines the order of rows within the physical file that holds the table. The
storage order has an effect on how you can partition the object.
store-option is defined as:
PRIMARY KEY
bases the clustering key on the primary key columns. This store option
requires that the primary key is NOT DROPPABLE. If the primary key is
defined as DROPPABLE, NonStop SQL/MX returns an error.
key-column-list
bases the clustering key on the columns in the key-column-list. The key
columns in key-column-list must be specified as NOT NULL NOT
DROPPABLE. It cannot have a combined length more than 2002 bytes for 4K
blocks and 2040 bytes for 32K blocks.
The default is PRIMARY KEY if you specified a PRIMARY KEY clause that has the
NOT DROPPABLE constraint in the CREATE TABLE statement.
If you omit the STORE BY clause and you do not specify a PRIMARY KEY that
has the NOT DROPPABLE constraint, the storage order is determined only by the
SYSKEY. You cannot partition a table stored only by SYSKEY. See SYSKEYs on
page 6-63.
LOCATION [\node.]$volume[.subvolume.file-name]
[NAME partition-name]
specifies a physical location for the primary partition of the table.
node
is the name of a node on the Expand network.
For Guardian files representing a table or index partition or a view label, node
can be any node from which the object's catalog is visible.
volume
is the name of an audited, non-SMF DAM volume on the specified node (or the
Guardian volume named in the =_DEFAULTS define if none is specified).