The CASCADE option allows you to drop a primary key or unique constraint that is referenced by foreign key constraints: the referencing foreign key constraints are also dropped.
Example (Oracle):
Code:
SQL> create table a (aid integer, constraint a_pk primary key (aid));
Table created.
SQL> create table b (bid integer, aid integer,
2 constraint b_pk primary key (bid),
3 constraint b_fk foreign key(aid) references a);
Table created.
SQL> select constraint_name from user_constraints where table_name='B';
CONSTRAINT_NAME
------------------------------
B_FK
B_PK
SQL> insert into a values (1);
1 row created.
SQL> insert into b values (11,1);
1 row created.
SQL> alter table a drop constraint a_pk;
alter table a drop constraint a_pk
*
ERROR at line 1:
ORA-02273: this unique/primary key is referenced by some foreign keys
SQL> alter table a drop constraint a_pk CASCADE;
Table altered.
SQL> select constraint_name from user_constraints where table_name='B';
CONSTRAINT_NAME
------------------------------
B_PK
As you can see, dropping the primary key of A with cascade caused the foreign key referencing A from B to be dropped also.