From 944965d310f08e27e5356af4150004c7334c4aee Mon Sep 17 00:00:00 2001 From: valdir Date: Tue, 15 Dec 2020 13:33:42 +0000 Subject: [PATCH] =?UTF-8?q?0020761:=20ESPEC=20-=20Cria=C3=A7=C3=A3o=20de?= =?UTF-8?q?=203=20tr=C3=AAs=20servi=C3=A7os=20no=20Doble=20Decker=20bug#20?= =?UTF-8?q?761=20dev:fabio=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@104724 d1611594-4594-4d17-8e1d-87c2c4800839 --- src/db/migration/V20200112_1934__mantis20761.sql | 15 +++++++++++++++ .../migration/V20200112_1934__mantis20761.sql | 6 ++++++ 2 files changed, 21 insertions(+) create mode 100644 src/db/migration/V20200112_1934__mantis20761.sql create mode 100644 src/db/postgresql/migration/V20200112_1934__mantis20761.sql diff --git a/src/db/migration/V20200112_1934__mantis20761.sql b/src/db/migration/V20200112_1934__mantis20761.sql new file mode 100644 index 000000000..fc568b836 --- /dev/null +++ b/src/db/migration/V20200112_1934__mantis20761.sql @@ -0,0 +1,15 @@ +declare + object_exists exception; + except_01451 exception; + except_01442 exception; + + pragma exception_init (object_exists , -01430); + pragma exception_init (except_01451 , -01451); + pragma exception_init (except_01442 , -01442); +begin + execute immediate 'ALTER TABLE ESQUEMA_CORRIDA ADD NUMCORRIDAPISOEXTRA2 NUMBER(7,0) '; + exception + when object_exists then null; + when except_01451 then null; + when except_01442 then null; +end; diff --git a/src/db/postgresql/migration/V20200112_1934__mantis20761.sql b/src/db/postgresql/migration/V20200112_1934__mantis20761.sql new file mode 100644 index 000000000..6ffd550a0 --- /dev/null +++ b/src/db/postgresql/migration/V20200112_1934__mantis20761.sql @@ -0,0 +1,6 @@ +DO $$ +BEGIN + ALTER TABLE ESQUEMA_CORRIDA ADD NUMCORRIDAPISOEXTRA2 NUMBER(7,0); + EXCEPTION WHEN unique_violation THEN NULL; +END +$$; \ No newline at end of file