declare
    object_exists exception;
    pragma exception_init (object_exists , -00955);
begin
  execute immediate
  	'CREATE SEQUENCE TAXPOLPUNTOVENTA_PK  MINVALUE 1 MAXVALUE 9999999 INCREMENT BY 1 START WITH 101 CACHE 20 NOORDER  NOCYCLE';	
  exception when object_exists then null;
end;
/
declare
    object_exists exception;
    pragma exception_init (object_exists , -00955);
begin
  execute immediate
  'CREATE TABLE TAXPOL_PUNTOVENTA
  (TAXPOLPUNTOVENTA_ID NUMBER(7,0) NOT NULL ENABLE, 
	PUNTOVENTA_ID NUMBER(7,0),  
	INDREIMPRESSAO NUMBER(1,0),
	FECMODIF DATE,
	ACTIVO NUMBER(1,0),
	CONSTRAINT TAXPOLPUNTOVENTA_PK PRIMARY KEY (TAXPOLPUNTOVENTA_ID) ENABLE,  
	FOREIGN KEY (PUNTOVENTA_ID) REFERENCES PUNTO_VENTA (PUNTOVENTA_ID) ON DELETE SET NULL  ENABLE)';
	exception when object_exists then null;
end;