AdmMono/src/db/migration/V20161229_1147__mantis8465.sql

14 lines
431 B
SQL

declare
object_exists exception;
except_02275 exception;
pragma exception_init (object_exists , -01430);
pragma exception_init (except_02275 , -02275);
begin
execute immediate 'ALTER TABLE NOTA_CREDITO_VENDA_PACOTE ADD CONSTRAINT FK_USUARIO_NC_PAG FOREIGN KEY (USUARIOPAGAMENTO_ID) REFERENCES USUARIO (USUARIO_ID)';
exception
when object_exists then null;
when except_02275 then null;
end;