Merge pull request 'Funcionalidade de adicao ao contrato feat bug#AL-4343' (!154) from AL-4343 into master

Reviewed-on: utilidades/Flyway#154
Reviewed-by: pinheiro <valdevir@rjconsultores.com.br>
master
fabio 2024-07-19 16:17:12 +00:00
commit 334c8ca8f6
4 changed files with 32 additions and 25 deletions

View File

@ -4,7 +4,7 @@
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>br.com.rjconsultores</groupId> <groupId>br.com.rjconsultores</groupId>
<artifactId>Flyway</artifactId> <artifactId>Flyway</artifactId>
<version>1.74.0</version> <version>1.75.0</version>
<distributionManagement> <distributionManagement>
<repository> <repository>

View File

@ -1,24 +0,0 @@
declare
object_exists exception;
pragma exception_init (object_exists , -00955);
begin
execute immediate 'CREATE TABLE TIPO_LANCAMENTO_CAIXA (
TIPO_LANCAMENTO_ID NUMBER(7,0) PRIMARY KEY,
NOME_LANCAMENTO VARCHAR2(255),
INDACRESCIMO NUMBER(1,0),
ACTIVO NUMBER(1,0),
USUARIO_ID NUMBER(7,0),
FECMODIF DATE,
CONSTRAINT fk_usuario_tipo_lancamento FOREIGN KEY (USUARIO_ID) REFERENCES USUARIO(USUARIO_ID)
)';
exception when object_exists then null;
end;
/
declare
object_exists exception;
pragma exception_init (object_exists , -00955);
begin
execute immediate 'CREATE SEQUENCE "TIPO_LANCAMENTO_CAIXA_SEQ" MINVALUE 1 MAXVALUE 9999999999999999999999999999 INCREMENT BY 1 START WITH 1 CACHE 20 NOORDER NOCYCLE';
exception when object_exists then null;
end;
/

View File

@ -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 CAIXA_CONTRATO ADD OBSERVACAO VARCHAR2(150)';
exception
when object_exists then null;
when except_01451 then null;
when except_01442 then null;
end;

View File

@ -0,0 +1,16 @@
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 CAIXA_CONTRATO DROP CONSTRAINT FK_TIPO_LANCAMENTO_CAIXA_CONTRATO';
exception
when object_exists then null;
when except_01451 then null;
when except_01442 then null;
end;
/