change fk to attr_def
This commit is contained in:
parent
34dc774aa8
commit
d4e87ebd94
1 changed files with 15 additions and 1 deletions
|
|
@ -1,3 +1,17 @@
|
|||
alter table attr_def add ad_extra text ;
|
||||
|
||||
insert into attr_def (ad_id,ad_text,ad_type,ad_size) values (33,'Date Fin','date',8);
|
||||
insert into attr_def (ad_id,ad_text,ad_type,ad_size) values (33,'Date Fin','date',8);
|
||||
|
||||
ALTER TABLE fiche_detail DROP CONSTRAINT "$2";
|
||||
|
||||
ALTER TABLE fiche_detail
|
||||
ADD CONSTRAINT fiche_detail_attr_def_fk FOREIGN KEY (ad_id)
|
||||
REFERENCES attr_def (ad_id) MATCH SIMPLE
|
||||
ON UPDATE cascade ON DELETE cascade;
|
||||
|
||||
ALTER TABLE jnt_fic_attr DROP CONSTRAINT "$2";
|
||||
|
||||
ALTER TABLE jnt_fic_attr
|
||||
ADD CONSTRAINT jnt_fic_attr_attr_def_fk FOREIGN KEY (ad_id)
|
||||
REFERENCES attr_def (ad_id) MATCH SIMPLE
|
||||
ON UPDATE cascade ON DELETE cascade;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue