CREATE TABLE TAXAADMFILGES (
  NRTAXAADMFILGES NUMBER(10) NOT NULL, 
  CDFILIAL VARCHAR2(4) NOT NULL, 
  CDANO NUMBER(10) NOT NULL, 
  VRMES01 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES02 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES03 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES04 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES05 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES06 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES07 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES08 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES09 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES10 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES11 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  VRMES12 DOUBLE PRECISION DEFAULT '0' NOT NULL, 
  NRORG NUMBER(10) DEFAULT SYS_CONTEXT('nrorg_ctx','nrorg') NOT NULL, 
  IDATIVO VARCHAR2(1) DEFAULT 'S' NOT NULL, 
  DTINCLUSAO DATE DEFAULT NULL NULL, 
  DTULTATU DATE DEFAULT NULL NULL, 
  NRORGINCLUSAO NUMBER(10) DEFAULT 1 NULL, 
  NRORGULTATU NUMBER(10) DEFAULT 1 NULL, 
  CDOPERINCLUSAO VARCHAR2(12) DEFAULT '1' NULL, 
  CDOPERULTATU VARCHAR2(12) DEFAULT '1' NULL,
  CONSTRAINT PK_TAXAADMFILGES PRIMARY KEY(NRTAXAADMFILGES)
)
/
ALTER TABLE TAXAADMFILGES ADD CONSTRAINT CKC_IDATIVO_TAXAADMFILGES CHECK (IDATIVO IN ('S','N'))
/
ALTER TABLE TAXAADMFILGES ADD CONSTRAINT FKGOP00720FILIAL FOREIGN KEY (CDFILIAL) REFERENCES FILIAL (CDFILIAL)
/
CREATE INDEX FKGOP00720FILIAL ON TAXAADMFILGES (CDFILIAL)