SQL/MX 3.1 Reference Manual (H06.23+, J06.12+)

SQL/MX Statements
HP NonStop SQL/MX Release 3.1 Reference Manual663850-001
2-106
Syntax Description of CREATE TABLE
When SET NULL is specified with the ON DELETE referential triggered
action, and a row from the referencing table matches the row in the
referenced-table, the referencing column(s) of the referencing row
from the referencing table is set to NULL.
When SET DEFAULT is specified with the ON DELETE referential
triggered action, and a row from the referencing table matches the row in
the referenced-table, the referencing column(s) of the referencing row
from the referencing table is set to its DEFAULT value.
When CASCADE is specified with the ON UPDATE referential triggered
action, a row in the referencing table and its corresponding row in the
referenced-table is updated.
When SET NULL is specified with the ON UPDATE referential triggered
action, and a row in the referencing table matches the row in the
referenced-table, the referencing column(s) of the referencing row
from the referencing table is set to NULL.
When SET DEFAULT is specified with the ON UPDATE referential
triggered action, and a row in the referencing table matches the row in the
referenced-table, the referencing column(s) of the referencing row
from the referencing table is set to its DEFAULT value.
referenced-table is the table referenced by the foreign key in a referential
constraint. referenced-table cannot be a view. referenced-table
cannot be the same as table.
column-list specifies the column or set of columns in referenced-table
that corresponds to the foreign key in table. The columns in the column list
associated with REFERENCES must be in the same order as the columns in
the column list associated with FOREIGN KEY. If column-list is omitted, the
referenced table’s PRIMARY KEY columns are the referenced columns.
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.
Note. The referential actions CASCADE, SET NULL, and SET DEFAULT are
available only on systems running J06.09 and later J-series RVUs and H06.20 and
later H-series RVUs.