diff --git a/src/db/migration/V20191219_1050__mantis17313.sql b/src/db/migration/V20191219_1050__mantis17313.sql new file mode 100644 index 000000000..68d6de529 --- /dev/null +++ b/src/db/migration/V20191219_1050__mantis17313.sql @@ -0,0 +1,8 @@ +declare + dup_val_on_index exception; + pragma exception_init (dup_val_on_index , -00001); +begin + execute immediate 'INSERT INTO TIPO_OPERACION_CC (TIPOOPERACIONCC_ID, DESCTIPO, CVETIPO, INDCREDITO, ACTIVO, FECMODIF, USUARIO_ID) VALUES (6, ''COBRANCA ADICIONAL'', ''CA'', 0, 1, SYSDATE, 99)'; + + exception when dup_val_on_index then null; +end; \ No newline at end of file diff --git a/src/db/postgresql/migration/V20191219_1050__mantis17313.sql b/src/db/postgresql/migration/V20191219_1050__mantis17313.sql new file mode 100644 index 000000000..3bc88bd2d --- /dev/null +++ b/src/db/postgresql/migration/V20191219_1050__mantis17313.sql @@ -0,0 +1,6 @@ +DO $$ +BEGIN + INSERT INTO TIPO_OPERACION_CC (TIPOOPERACIONCC_ID, DESCTIPO, CVETIPO, INDCREDITO, ACTIVO, FECMODIF, USUARIO_ID) VALUES (6, 'COBRANCA ADICIONAL', 'CA', 0, 1, SYSDATE, 99); + EXCEPTION WHEN duplicate_object THEN NULL; +END +$$; \ No newline at end of file