From 07c5aedd27299db25d8a3c1ea56abd4c7095148b Mon Sep 17 00:00:00 2001 From: valdir Date: Fri, 10 Jun 2022 17:45:14 +0000 Subject: [PATCH] =?UTF-8?q?0024539:=20GLPI=2051302=20-=20Espec=20Validar?= =?UTF-8?q?=20Benef=C3=ADcio=20Idoso=20bug#24539=20dev:valdevir=20qua:?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/BD/FlyWay/trunk@112708 d1611594-4594-4d17-8e1d-87c2c4800839 --- src/db/migration/V20220608_1022__mantis24539.sql | 7 +++++++ .../postgresql/migration/V20220608_1022__mantis24539.sql | 6 ++++++ 2 files changed, 13 insertions(+) create mode 100644 src/db/migration/V20220608_1022__mantis24539.sql create mode 100644 src/db/postgresql/migration/V20220608_1022__mantis24539.sql diff --git a/src/db/migration/V20220608_1022__mantis24539.sql b/src/db/migration/V20220608_1022__mantis24539.sql new file mode 100644 index 000000000..bbf93b4b0 --- /dev/null +++ b/src/db/migration/V20220608_1022__mantis24539.sql @@ -0,0 +1,7 @@ +declare + column_exists exception; + pragma exception_init (column_exists , -01430); +begin + execute immediate 'ALTER TABLE CATEGORIA_DESCUENTO ADD (INDEXIGENUMFIDELIDADE NUMBER(1,0) )'; + exception when column_exists then null; +end; diff --git a/src/db/postgresql/migration/V20220608_1022__mantis24539.sql b/src/db/postgresql/migration/V20220608_1022__mantis24539.sql new file mode 100644 index 000000000..c6cda1d2e --- /dev/null +++ b/src/db/postgresql/migration/V20220608_1022__mantis24539.sql @@ -0,0 +1,6 @@ +DO $$ +BEGIN + ALTER TABLE CATEGORIA_DESCUENTO ADD (INDEXIGENUMFIDELIDADE NUMBER(1,0) ); + EXCEPTION WHEN duplicate_column THEN NULL; +END +$$; \ No newline at end of file