From 447e047e3a65544e4a443fe61dd1ef4ba4ee0f74 Mon Sep 17 00:00:00 2001 From: wilian Date: Wed, 25 Sep 2019 14:02:28 +0000 Subject: [PATCH] fixes bug#14990 dev:lucas qua: git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/BD/FlyWay/trunk@97819 d1611594-4594-4d17-8e1d-87c2c4800839 --- src/db/migration/V20190923_1105__mantis14990.sql | 10 ++++++++++ .../migration/V20190923_1105__mantis14990.sql | 9 +++++++++ 2 files changed, 19 insertions(+) create mode 100644 src/db/migration/V20190923_1105__mantis14990.sql create mode 100644 src/db/postgresql/migration/V20190923_1105__mantis14990.sql diff --git a/src/db/migration/V20190923_1105__mantis14990.sql b/src/db/migration/V20190923_1105__mantis14990.sql new file mode 100644 index 000000000..d3cf89e7f --- /dev/null +++ b/src/db/migration/V20190923_1105__mantis14990.sql @@ -0,0 +1,10 @@ +declare + column_exists exception; + pragma exception_init (column_exists , -01430); +begin + execute immediate 'ALTER TABLE GP_PRICING ADD (INDESTADIAMINIMA NUMBER(1), CANTDIAS_ESTADIAMINIMA NUMBER(3), + INDLUN_ESTADIAMINIMA NUMBER(1), INDMAR_ESTADIAMINIMA NUMBER(1), INDMIE_ESTADIAMINIMA NUMBER(1), + INDJUE_ESTADIAMINIMA NUMBER(1), INDVIE_ESTADIAMINIMA NUMBER(1), INDSAB_ESTADIAMINIMA NUMBER(1), + INDDOM_ESTADIAMINIMA NUMBER(1))'; + exception when column_exists then null; +end; \ No newline at end of file diff --git a/src/db/postgresql/migration/V20190923_1105__mantis14990.sql b/src/db/postgresql/migration/V20190923_1105__mantis14990.sql new file mode 100644 index 000000000..2a56545d5 --- /dev/null +++ b/src/db/postgresql/migration/V20190923_1105__mantis14990.sql @@ -0,0 +1,9 @@ +DO $$ +BEGIN + ALTER TABLE GP_PRICING ADD (INDESTADIAMINIMA NUMBER(1), CANTDIAS_ESTADIAMINIMA NUMBER(3), + INDLUN_ESTADIAMINIMA NUMBER(1), INDMAR_ESTADIAMINIMA NUMBER(1), INDMIE_ESTADIAMINIMA NUMBER(1), + INDJUE_ESTADIAMINIMA NUMBER(1), INDVIE_ESTADIAMINIMA NUMBER(1), INDSAB_ESTADIAMINIMA NUMBER(1), + INDDOM_ESTADIAMINIMA NUMBER(1)); + EXCEPTION WHEN duplicate_column THEN NULL; +END +$$; \ No newline at end of file