AdmMono/src/db/migration/V20170710_1803__mantis9356.sql

17 lines
523 B
SQL

declare
object_exists exception;
pragma exception_init (object_exists , -00001);
begin
execute immediate 'update USUARIO set TEMPODEVOLUCAOPASSAGEM = -1 where TEMPODEVOLUCAOPASSAGEM = 0 OR TEMPODEVOLUCAOPASSAGEM is null';
exception when object_exists then null;
end;
/
declare
object_exists exception;
pragma exception_init (object_exists , -01451);
begin
execute immediate 'ALTER TABLE USUARIO MODIFY (TEMPODEVOLUCAOPASSAGEM DEFAULT -1 )';
exception when object_exists then null;
end;