CREATE TABLE APPCONFIG (
  NRAPPCONFIG NUMBER(10) NOT NULL, 
  DSDNS VARCHAR2(2000) NOT NULL, 
  DSPORTA VARCHAR2(30) NOT NULL, 
  IDAPLICATIVO VARCHAR2(30) NOT NULL, 
  NRORG NUMBER(10) DEFAULT 1 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, 
  CDOPERINCLUSAO VARCHAR2(12) DEFAULT '1' NULL, 
  NRORGULTATU NUMBER(10) DEFAULT 1 NULL, 
  CDOPERULTATU VARCHAR2(12) DEFAULT '1' NULL,
  CONSTRAINT PK_APPCONFIG PRIMARY KEY(NRAPPCONFIG)
)
/
ALTER TABLE APPCONFIG ADD CONSTRAINT CKC_IDATIVO_APPCONFIG CHECK (IDATIVO IN ('S','N'))
/
ALTER TABLE APPCONFIG ADD CONSTRAINT CKC_IDAPLICATIVO_APPCONFIG CHECK (IDAPLICATIVO IN ('MYMENU','MYQUEST'))