ALTER TABLE PESSOA DROP CONSTRAINT FKMYO00636CLIENTE
/
ALTER TABLE PESSOA ADD CONSTRAINT FKMYO00001CLIENTE FOREIGN KEY (CDCLIENTE, NRORG) REFERENCES CLIENTE (CDCLIENTE, NRORG)
/
DROP INDEX MYO00636_FK
/
CREATE INDEX FKMYO00001CLIENTE ON PESSOA (CDCLIENTE, NRORG)
/
ALTER TABLE PEDIDOSERV DROP CONSTRAINT FKMYO00637FILIAL
/
DROP INDEX MYO00637_FK
/
ALTER TABLE PEDIDOSERV DROP CONSTRAINT FKMYO00638CLIENTE
/
DROP INDEX MYO00638_FK
/
ALTER TABLE PEDIDOSERV DROP CONSTRAINT FKMYO00639PESSOA
/
DROP INDEX MYO00639_FK
/
ALTER TABLE PEDIDOSERV DROP CONSTRAINT FKMYO00640NOTAFISCAL
/
DROP INDEX MYO00640_FK
/
ALTER TABLE PEDIDOSERV ADD CONSTRAINT FKMYO00002FILIAL FOREIGN KEY (CDFILIAL, NRORG) REFERENCES FILIAL (CDFILIAL, NRORG)
/
CREATE INDEX FKMYO00002FILIAL ON PEDIDOSERV (CDFILIAL, NRORG)
/
ALTER TABLE PEDIDOSERV ADD CONSTRAINT FKMYO00003CLIENTE FOREIGN KEY (CDCLIENTE, NRORG) REFERENCES CLIENTE (CDCLIENTE, NRORG)
/
CREATE INDEX FKMYO00003CLIENTE ON PEDIDOSERV (CDCLIENTE, NRORG)
/
ALTER TABLE PEDIDOSERV ADD CONSTRAINT FKMYO00004PESSOA FOREIGN KEY (NRPESSOA, NRORG) REFERENCES PESSOA (NRPESSOA, NRORG)
/
CREATE INDEX FKMYO00004PESSOA ON PEDIDOSERV (NRPESSOA, NRORG)
/
ALTER TABLE PEDIDOSERV ADD CONSTRAINT FKMYO00005NOTAFISCAL FOREIGN KEY(CDFILIAL, NRLANCTONF, NRORG) REFERENCES NOTAFISCAL (CDFILIAL, NRLANCTONF, NRORG)
/
CREATE INDEX FKMYO00005NOTAFISCAL ON PEDIDOSERV (CDFILIAL, NRLANCTONF, NRORG)