diff --git a/src/db/migration/V20200114_1129__mantis17842.sql b/src/db/migration/V20200114_1129__mantis17842.sql new file mode 100644 index 000000000..b02b63792 --- /dev/null +++ b/src/db/migration/V20200114_1129__mantis17842.sql @@ -0,0 +1,7 @@ +declare + column_exists exception; + pragma exception_init (column_exists , -01430); +begin + execute immediate 'ALTER TABLE CONSTANTE MODIFY DESCCONSTANTE VARCHAR2(200)'; + exception when column_exists then null; +end; \ No newline at end of file diff --git a/src/db/migration/V20200114_1130__mantis17842.sql b/src/db/migration/V20200114_1130__mantis17842.sql new file mode 100644 index 000000000..b881fa6ec --- /dev/null +++ b/src/db/migration/V20200114_1130__mantis17842.sql @@ -0,0 +1,6 @@ +declare + begin + execute immediate 'INSERT INTO CONSTANTE (CONSTANTE_ID, NOMBCONSTANTE, DESCCONSTANTE, VALORCONSTANTE, INDTIPOCONSTANTE, INDMANTENIMIENTOUSUARIO, ACTIVO, FECMODIF, USUARIO_ID) + VALUES (CONSTANTE_SEQ.nextval, ''BPE_CONTINGENCIA_AUTOMATICA'', ''ATIVA CONTINGENCIA AUTOMATICA EM CASO DE TIMEOUT SEFAZ'', ''FALSE'', ''1'', ''1'', ''1'', sysdate, ''1'')'; + exception when others then null; +end; \ No newline at end of file diff --git a/src/db/migration/V20200114_1131__mantis17842.sql b/src/db/migration/V20200114_1131__mantis17842.sql new file mode 100644 index 000000000..4a3d618fd --- /dev/null +++ b/src/db/migration/V20200114_1131__mantis17842.sql @@ -0,0 +1,7 @@ +declare + column_exists exception; + pragma exception_init (column_exists , -01430); +begin + execute immediate 'ALTER TABLE LOG_HISTORICO_CONTINGENCIA ADD (INDAUTOMATICA NUMBER(1))'; + exception when column_exists then null; +end; \ No newline at end of file diff --git a/src/db/migration/V20200115_1138__mantis17842.sql b/src/db/migration/V20200115_1138__mantis17842.sql new file mode 100644 index 000000000..5d221e933 --- /dev/null +++ b/src/db/migration/V20200115_1138__mantis17842.sql @@ -0,0 +1,6 @@ +declare + begin + execute immediate 'INSERT INTO CONSTANTE (CONSTANTE_ID, NOMBCONSTANTE, DESCCONSTANTE, VALORCONSTANTE, INDTIPOCONSTANTE, INDMANTENIMIENTOUSUARIO, ACTIVO, FECMODIF, USUARIO_ID) + VALUES (CONSTANTE_SEQ.nextval, ''BPE_QTDE_TIMEOUT_SEFAZ'', ''CONTADOR DE TIMEOUTS SEFAZ PARA ATIVACAO CONTINGENCIA AUTOMATICA'', ''15'', ''1'', ''1'', ''1'', sysdate, ''1'')'; + exception when others then null; +end; \ No newline at end of file diff --git a/src/db/migration/V20200115_1139__mantis17842.sql b/src/db/migration/V20200115_1139__mantis17842.sql new file mode 100644 index 000000000..bf7141c50 --- /dev/null +++ b/src/db/migration/V20200115_1139__mantis17842.sql @@ -0,0 +1,6 @@ +declare + begin + execute immediate 'INSERT INTO CONSTANTE (CONSTANTE_ID, NOMBCONSTANTE, DESCCONSTANTE, VALORCONSTANTE, INDTIPOCONSTANTE, INDMANTENIMIENTOUSUARIO, ACTIVO, FECMODIF, USUARIO_ID) + VALUES (CONSTANTE_SEQ.nextval, ''BPE_TEMPO_REMOVE_CONTINGENCIA_AUTOMATICA'', ''TEMPO PARA REMOVER CONTINGENCIA AUTOMATICA VIA TIMEOUT (EM MINUTOS)'', ''5'', ''1'', ''1'', ''1'', sysdate, ''1'')'; + exception when others then null; +end; \ No newline at end of file diff --git a/src/db/postgresql/migration/V20200114_1131__mantis17842.sql b/src/db/postgresql/migration/V20200114_1131__mantis17842.sql new file mode 100644 index 000000000..87325ac84 --- /dev/null +++ b/src/db/postgresql/migration/V20200114_1131__mantis17842.sql @@ -0,0 +1,6 @@ +DO $$ +BEGIN + ALTER TABLE LOG_HISTORICO_CONTINGENCIA ADD (INDAUTOMATICA NUMBER(1)); + EXCEPTION WHEN duplicate_column THEN NULL; +END +$$; \ No newline at end of file