CREATE TABLE ENDPARTSPED (
   INSCRICAO    VARCHAR2(20) NOT NULL, 
   PAIS         VARCHAR2(4), 
   ESTADO       VARCHAR2(2), 
   MUNICIPIO    VARCHAR2(4), 
   ENDERECO     VARCHAR2(100), 
   NUMERO       VARCHAR2(10),
   COMPLEMENTO  VARCHAR2(200),  
   BAIRRO       VARCHAR2(50),
   PARTICIPANTE  VARCHAR2(4000) NOT NULL,
   CONSTRAINT PK_ENDPARTSPED PRIMARY KEY (PARTICIPANTE),
   NRORG             NUMBER 	     DEFAULT         SYS_CONTEXT('nrorg_ctx','nrorg') NOT NULL,
   IDATIVO           VARCHAR2(1)     DEFAULT 'S' NOT NULL
      CONSTRAINT CKC_IDATIVO_ENDPARTSPED CHECK (IDATIVO IN ('S','N')),
   DTINCLUSAO        DATE                  			NULL,
   DTULTATU          DATE                  			NULL,
   NRORGINCLUSAO     NUMBER          DEFAULT SYS_CONTEXT('nrorg_ctx','nrorg')		NULL,
   CDOPERINCLUSAO    VARCHAR2(12)    DEFAULT '1' 		NULL,
   NRORGULTATU       NUMBER          DEFAULT SYS_CONTEXT('nrorg_ctx','nrorg')		NULL,
   CDOPERULTATU      VARCHAR2(12)    DEFAULT '1'	
)
/
ALTER TABLE PARAMFISCAL
   ADD IDORCLVER10 VARCHAR2(01) DEFAULT 'N' NOT NULL 
      CONSTRAINT CKC_IDORCLVER10_PARAMFISCAL CHECK (IDORCLVER10 IN ('S','N'))
/