ALTER TABLE FCT_CONTRATO ADD IDGERARATEIO CHAR(1) DEFAULT 'N' NOT NULL
/

ALTER TABLE FCT_CONTRATO ADD CONSTRAINT CKC_IDGERARATEIO_CONTRATO CHECK (IDGERARATEIO IN ('S', 'N'))
/

ALTER TABLE FCT_RELACESTRUTURACONT ADD IDLOCALTOMADORNF VARCHAR2(1) DEFAULT 'N' NOT NULL
/

ALTER TABLE FCT_RELACESTRUTURACONT ADD CONSTRAINT CKC_IDLOCALTOMNF_RELESTCONT CHECK (IDLOCALTOMADORNF IN ('S', 'N'))
/

ALTER TABLE FCT_NEGOCIACAOCONTRATO ADD NRESTRUTURAM NUMBER
/

CREATE INDEX SM00368_FK ON FCT_NEGOCIACAOCONTRATO (NRESTRUTURAM ASC)
/

ALTER TABLE FCT_NEGOCIACAOCONTRATO ADD CONSTRAINT FKSM00368ESTRUTURAM_NEGCONT
    FOREIGN KEY (NRESTRUTURAM) REFERENCES ESTRUTURAM (NRESTRUTURAM)
/