1、data integrity:app code ,db trigger, integrity constraint 优先级增高
2、constraints type: not null,unique,primary key,foreign key,check
3、unique: allow null value foreign key:allow null value
4、primary key: alter table (enable|disable) (novalidate|validate) primary key
5、pk immediate每条语句后检查, deferralbe生成nounique索引,在commit时统一检查约束
SET CONSTRAINTS ALL DEFERRED;
SET CONSTRAINT XXX DEFERRED;
6、子表外键应建索引,增加并发性
7、导数据的时候 2步:enable novalidate,enable validate
8、exceptions to table
数据字典:
dba_constraints
dba_cons_column