diff --git a/src/db/migration/V20200929_1500__mantis20523.sql b/src/db/migration/V20200929_1500__mantis20523.sql new file mode 100644 index 000000000..d07cf1d03 --- /dev/null +++ b/src/db/migration/V20200929_1500__mantis20523.sql @@ -0,0 +1,15 @@ +declare + column_exists exception; + pragma exception_init (column_exists , -01430); +begin + execute immediate 'ALTER TABLE FORMA_PAGO ADD TIPOEVENTOEXTRA_ID NUMBER(7,0)'; + exception when column_exists then null; +end; +/ +declare + column_exists exception; + pragma exception_init (column_exists , -01430); +begin + execute immediate 'UPDATE CONSTANTE SET ACTIVO = 0 WHERE NOMBCONSTANTE LIKE ''TEE_ESTORNO_ELETRONICO_CARTAO'''; + exception when column_exists then null; +end; diff --git a/src/db/postgresql/migration/V20200929_1500__mantis20523.sql b/src/db/postgresql/migration/V20200929_1500__mantis20523.sql new file mode 100644 index 000000000..2d32a231d --- /dev/null +++ b/src/db/postgresql/migration/V20200929_1500__mantis20523.sql @@ -0,0 +1,13 @@ +DO $$ +BEGIN + ALTER TABLE FORMA_PAGO ADD TIPOEVENTOEXTRA_ID NUMBER(7,0); + EXCEPTION WHEN duplicate_column THEN NULL; +END +$$; +/ +DO $$ +BEGIN + UPDATE CONSTANTE SET ACTIVO = 0 WHERE NOMBCONSTANTE LIKE 'TEE_ESTORNO_ELETRONICO_CARTAO'; + EXCEPTION WHEN duplicate_column THEN NULL; +END +$$;