leonardo 2017-07-04 20:18:35 +00:00
parent 0a5d6dddbf
commit 36295a7ed1
1 changed files with 16 additions and 17 deletions

View File

@ -1,3 +1,19 @@
declare
object_exists exception;
pragma exception_init (object_exists , -00001);
begin
execute immediate 'update CATEGORIA_DESCUENTO set indSegunda = 1 where indSegunda is null';
execute immediate 'update CATEGORIA_DESCUENTO set indTerca = 1 where indTerca is null';
execute immediate 'update CATEGORIA_DESCUENTO set indQuarta = 1 where indQuarta is null';
execute immediate 'update CATEGORIA_DESCUENTO set indQuinta = 1 where indQuinta is null';
execute immediate 'update CATEGORIA_DESCUENTO set indSexta = 1 where indSexta is null';
execute immediate 'update CATEGORIA_DESCUENTO set indSabado = 1 where indSabado is null';
execute immediate 'update CATEGORIA_DESCUENTO set indDomingo = 1 where indDomingo is null';
exception when object_exists then null;
end;
/
declare
object_exists exception;
pragma exception_init (object_exists , -01451);
@ -11,20 +27,3 @@ begin
execute immediate 'ALTER TABLE CATEGORIA_DESCUENTO MODIFY (INDDOMINGO NOT NULL)';
exception when object_exists then null;
end;
/
declare
object_exists exception;
pragma exception_init (object_exists , -01451);
begin
execute immediate 'update CATEGORIA_DESCUENTO set indSegunda = 1 where indSegunda is null';
execute immediate 'update CATEGORIA_DESCUENTO set indTerca = 1 where indTerca is null';
execute immediate 'update CATEGORIA_DESCUENTO set indQuarta = 1 where indQuarta is null';
execute immediate 'update CATEGORIA_DESCUENTO set indQuinta = 1 where indQuinta is null';
execute immediate 'update CATEGORIA_DESCUENTO set indSexta = 1 where indSexta is null';
execute immediate 'update CATEGORIA_DESCUENTO set indSabado = 1 where indSabado is null';
execute immediate 'update CATEGORIA_DESCUENTO set indDomingo = 1 where indDomingo is null';
exception when object_exists then null;
end;