--------------------------------------------------------
--  File created - Wednesday-September-30-2015   
--------------------------------------------------------
--------------------------------------------------------
--  DDL for Table LU_QA_AGENCY
--------------------------------------------------------

  CREATE TABLE "STORETW"."LU_QA_AGENCY" 
   (	"PK_ISN" NUMBER(12,0), 
	"QA_AGENCY_NAME" VARCHAR2(256 CHAR)
   ) SEGMENT CREATION IMMEDIATE 
  PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 
 COMPRESS FOR OLTP NOLOGGING
  STORAGE(INITIAL 163840 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
  BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
  TABLESPACE "STORETDATA_STORMODP" ;

   COMMENT ON COLUMN "STORETW"."LU_QA_AGENCY"."PK_ISN" IS 'Primary Key. Generated using sequence object SEQ_LU_QA_AGENCY.';
   COMMENT ON COLUMN "STORETW"."LU_QA_AGENCY"."QA_AGENCY_NAME" IS 'Agency name';
   COMMENT ON TABLE "STORETW"."LU_QA_AGENCY"  IS 'QA agency look up table';
REM INSERTING into STORETW.LU_QA_AGENCY
SET DEFINE OFF;
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (51,'U.S.EPA');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (11,'US EPA REGION 7');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (21,'ENVIRONMENTAL PROTECTION AGENCY');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (31,'NEW JERSEY DEPARTMENT OF ENVIRONMENTAL PROTECTION');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (1,'USEPA R10');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (2,'EPA');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (3,'U.S. EPA');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (4,'EPA OW AND ORD');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (5,'OTHER AGENCY');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (6,'MONTANA DEQ');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (7,'NJDEP OFFICE OF QUALITY ASSURANCE');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (8,'ADEC');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (9,'GA EPD');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (10,'US EPA');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (81,'DNR');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (101,'USEPA');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (111,'21VASWCB');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (61,'MDNR');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (62,'DEC');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (71,'EPA OW AND ORD AND REGION 2');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (41,'US EPA REGION 10');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (91,'IOWA DNR');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (121,'CONNECTICUT DEPARTMENT OF ENERGY AND ENVIRONMENTAL');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (122,'CT DPH MICROBIOLOGY');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (123,'ARC');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (124,'U.S. ENVIRONMENTAL PROTECTION AGENCY (EPA)');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (151,'IDNR');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (221,'CDPHE-BRIDGE TO TMDL');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (271,'CDPHE WQCD');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (131,'CA STATE WATER RESOURCES CONTROL BOARD');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (171,'COLORADO DEPARTMENT OF PUBLIC HEALTH & ENVIRONMENT');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (201,'DEQ');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (202,'GBSTF');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (211,'USEPA REGION 6');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (251,'US-EPA R4');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (261,'EPA REGION 6');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (321,'EPA OFFICE OF WATER');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (341,'EPA QTRAK #13-043');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (181,'NJDEP VOLUNTEER WATER MONITORING');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (231,'NYSDEC_DOW');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (241,'US-EPA R4, WPD, COPS');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (281,'US-EPA R1');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (311,'MPCA');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (331,'UNITED STATES ENVIRONMENTAL PROTECTION AGENCY');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (141,'ID DEPT OF ENVIRONMENTAL QUALITY AND USEPA');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (142,'ID DEPT OF ENVIRONMENTAL QUALITY');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (161,'CDPHE');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (191,'WQCD');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (192,'NONE');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (291,'MARYLAND DEPARTMENT OF THE ENVIRONMENT');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (292,'MARYLAND DEPARTMENT OF THE ENVIRONMENT (MDE)');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (301,'EPA R8');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (351,'DEC (BEACH)');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (352,'ADEC (BEACH)');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (361,'EPA REGION 10');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (362,'NEIWPCC/NYSDEC');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (371,'NJ DEP, WM&S, BEARS');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (514,'ADF&G, ADEC');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (515,'BLM');
Insert into STORETW.LU_QA_AGENCY (PK_ISN,QA_AGENCY_NAME) values (516,'AK DEC');
--------------------------------------------------------
--  DDL for Index ILQAA_QA_AGENCY_NAME
--------------------------------------------------------

  CREATE UNIQUE INDEX "STORETW"."ILQAA_QA_AGENCY_NAME" ON "STORETW"."LU_QA_AGENCY" (UPPER("QA_AGENCY_NAME")) 
  PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS NOLOGGING 
  STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
  BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
  TABLESPACE "STORETINDX_STORMODP" ;
--------------------------------------------------------
--  DDL for Index PK_QA_AGENCY
--------------------------------------------------------

  CREATE UNIQUE INDEX "STORETW"."PK_QA_AGENCY" ON "STORETW"."LU_QA_AGENCY" ("PK_ISN") 
  PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS NOLOGGING 
  STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
  BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
  TABLESPACE "STORETDATA_STORMODP" ;
--------------------------------------------------------
--  Constraints for Table LU_QA_AGENCY
--------------------------------------------------------

  ALTER TABLE "STORETW"."LU_QA_AGENCY" ADD CONSTRAINT "PK_QA_AGENCY" PRIMARY KEY ("PK_ISN")
  USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS NOLOGGING 
  STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
  BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
  TABLESPACE "STORETDATA_STORMODP"  ENABLE;
  ALTER TABLE "STORETW"."LU_QA_AGENCY" MODIFY ("PK_ISN" NOT NULL ENABLE);
