From 54bb34420f77619c9ce9c94d3458b5cb5384c7e0 Mon Sep 17 00:00:00 2001 From: "bruno.neves" Date: Wed, 21 Jun 2017 13:36:23 +0000 Subject: [PATCH] =?UTF-8?q?fix=20bug=20#0009138=20-=20corrigindo=20erro=20?= =?UTF-8?q?gerado=20na=20venda,=20o=20tempo=20de=20devolu=C3=A7=C3=A3o=20p?= =?UTF-8?q?assagem=20n=C3=A3o=20pode=20ser=20null=20!?= 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@70278 d1611594-4594-4d17-8e1d-87c2c4800839 --- src/db/migration/V20170621_0832__mantis9138.sql | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 src/db/migration/V20170621_0832__mantis9138.sql diff --git a/src/db/migration/V20170621_0832__mantis9138.sql b/src/db/migration/V20170621_0832__mantis9138.sql new file mode 100644 index 000000000..f04fa077d --- /dev/null +++ b/src/db/migration/V20170621_0832__mantis9138.sql @@ -0,0 +1,15 @@ +declare + dup_val_on_index exception; + pragma exception_init (dup_val_on_index , -00001); +begin + execute immediate 'UPDATE USUARIO SET TEMPODEVOLUCAOPASSAGEM = 0 WHERE TEMPODEVOLUCAOPASSAGEM IS NULL'; + exception when dup_val_on_index then null; +end; +/ +declare + object_exists exception; + pragma exception_init (object_exists , -00955); +begin + execute immediate 'ALTER TABLE USUARIO MODIFY (TEMPODEVOLUCAOPASSAGEM DEFAULT 0 NOT NULL)'; + exception when object_exists then null; +end; \ No newline at end of file