Scalable Database Server, HiRDB Version 8 Command Reference
This section presents four examples of pdconstck.
This example performs integrity checking on all constraints (CST1 and CST2) that have been defined for table T2. The example assumes that table T2 is in check pending status.
T1: CREATE TABLE T1(C1 INT PRIMARY KEY)
T3: CREATE TABLE T3(C2 INT PRIMARY KEY)
T2: CREATE TABLE T2(C1 INT, C2 INT,
CONSTRAINT CST1 FOREIGN KEY (C1) REFERENCES T1,
CONSTRAINT CST2 FOREIGN KEY (C2) REFERENCES T3)
|
pdconstck -k check -t T2 |
This example performs integrity checking on constraint CST2 defined for table T2. The table definitions are the same as in (1), and the example assumes that table T2 is in check pending status. |
pdconstck -k check -c CST2 |
This example performs integrity checking on all constraints (CST1 and CST2) that have been defined for table T2. The example assumes that table T2 is in non-check pending status.
T1: CREATE TABLE T1(C1 INT PRIMARY KEY)
T2: CREATE TABLE T2(C1 INT, C2 INT,
CONSTRAINT CST1 FOREIGN KEY (C1) REFERENCES T1,
CONSTRAINT CST2 CHECK (c2 > 10))
|
pdconstck -k set -t T2 |
This example forcibly releases constraint CST2 for table T2 from check pending status. The table definitions are the same as in (3), and the example assumes that constraint CST2 is in check pending status. |
pdconstck -k release -c CST2 |
All Rights Reserved. Copyright (C) 2007, Hitachi, Ltd.