--------------------------------------------------------
--  File created - Friday-December-09-2016   
--------------------------------------------------------
--------------------------------------------------------
--  DDL for Table CHANNELS
--------------------------------------------------------

  CREATE TABLE "CHANNELS" ("CHANNEL_ID" CHAR(1), "CHANNEL_DESC" VARCHAR2(20), "CHANNEL_CLASS" VARCHAR2(20)) SEGMENT CREATION IMMEDIATE PCTFREE 5 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING STORAGE(INITIAL 16384 NEXT 16384 MINEXTENTS 1 MAXEXTENTS 505 PCTINCREASE 50 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) ;

REM INSERTING into CHANNELS
SET DEFINE OFF;
Insert into CHANNELS (CHANNEL_ID,CHANNEL_DESC,CHANNEL_CLASS) values ('S','Direct Sales','Direct');
Insert into CHANNELS (CHANNEL_ID,CHANNEL_DESC,CHANNEL_CLASS) values ('T','Tele Sales','Direct');
Insert into CHANNELS (CHANNEL_ID,CHANNEL_DESC,CHANNEL_CLASS) values ('C','Catalog','Indirect');
Insert into CHANNELS (CHANNEL_ID,CHANNEL_DESC,CHANNEL_CLASS) values ('I','Internet','Indirect');
Insert into CHANNELS (CHANNEL_ID,CHANNEL_DESC,CHANNEL_CLASS) values ('P','Partners','Others');
--------------------------------------------------------
--  DDL for Index CHAN_PK
--------------------------------------------------------

  CREATE UNIQUE INDEX "CHAN_PK" ON "CHANNELS" ("CHANNEL_ID") PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS  STORAGE(INITIAL 16384 NEXT 16384 MINEXTENTS 1 MAXEXTENTS 505 PCTINCREASE 50 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) ;
--------------------------------------------------------
--  Constraints for Table CHANNELS
--------------------------------------------------------

  ALTER TABLE "CHANNELS" MODIFY ("CHANNEL_DESC" CONSTRAINT "CHAN_DESC_NN" NOT NULL ENABLE);
  ALTER TABLE "CHANNELS" ADD CONSTRAINT "CHAN_PK" PRIMARY KEY ("CHANNEL_ID") RELY USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS  STORAGE(INITIAL 16384 NEXT 16384 MINEXTENTS 1 MAXEXTENTS 505 PCTINCREASE 50 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) ENABLE;
