alter table 要建的表明add constraint 外键表 foreign key(外键类容) references 外键(外键id) on delete restrict on update restrict;