fixed bug #8662 - Alteração em código para permitir a restrição do tipo de OCD por ponto de venda.
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/BD/FlyWay/trunk@66281 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
883cd27569
commit
9f46abf3b5
|
@ -0,0 +1,19 @@
|
||||||
|
declare
|
||||||
|
table_exists exception;
|
||||||
|
pragma exception_init (table_exists , -00955);
|
||||||
|
begin
|
||||||
|
execute immediate
|
||||||
|
'create table OCD_PTOVTA_PARAM (OCDPTOVTAPARAM_ID NUMBER(15,0),
|
||||||
|
OCDPARAM_ID NUMBER(15,0),
|
||||||
|
PUNTOVENTA_ID NUMBER(15,0),
|
||||||
|
ACTIVO NUMBER(1,0),
|
||||||
|
FECMODIF DATE,
|
||||||
|
USUARIO_ID NUMBER(7,0),
|
||||||
|
PRIMARY KEY ("OCDPTOVTAPARAM_ID"),
|
||||||
|
FOREIGN KEY ("OCDPARAM_ID")
|
||||||
|
REFERENCES "VTABOL"."OCD_PARAM"("OCDPARAM_ID"),
|
||||||
|
FOREIGN KEY ("PUNTOVENTA_ID")
|
||||||
|
REFERENCES "VTABOL"."PUNTO_VENTA"("PUNTOVENTA_ID")
|
||||||
|
)';
|
||||||
|
exception when table_exists then null;
|
||||||
|
end;
|
|
@ -0,0 +1,9 @@
|
||||||
|
declare
|
||||||
|
object_exists exception;
|
||||||
|
pragma exception_init (object_exists , -00955);
|
||||||
|
begin
|
||||||
|
execute immediate 'CREATE SEQUENCE OCD_PTOVTA_PARAM_SEQ
|
||||||
|
MINVALUE 1 MAXVALUE 9999999999999999999999999999 INCREMENT BY 1
|
||||||
|
START WITH 1 CACHE 20 NOORDER NOCYCLE';
|
||||||
|
exception when object_exists then null;
|
||||||
|
end;
|
Loading…
Reference in New Issue