-- created by Oraschemadoc Fri Jun 13 14:05:54 2008
-- visit http://www.yarpen.cz/oraschemadoc/ for more info

  CREATE TABLE "RHNSAT"."RHNSERVER" 
   (	"ID" NUMBER CONSTRAINT "RHN_SERVER_ID_NN" NOT NULL ENABLE, 
	"ORG_ID" NUMBER CONSTRAINT "RHN_SERVER_OID_NN" NOT NULL ENABLE, 
	"DIGITAL_SERVER_ID" VARCHAR2(64) CONSTRAINT "RHN_SERVER_DSI_NN" NOT NULL ENABLE, 
	"SERVER_ARCH_ID" NUMBER CONSTRAINT "RHN_SERVER_SAID_NN" NOT NULL ENABLE, 
	"OS" VARCHAR2(64) CONSTRAINT "RHN_SERVER_OS_NN" NOT NULL ENABLE, 
	"RELEASE" VARCHAR2(64) CONSTRAINT "RHN_SERVER_RELEASE_NN" NOT NULL ENABLE, 
	"NAME" VARCHAR2(128), 
	"DESCRIPTION" VARCHAR2(256), 
	"INFO" VARCHAR2(128), 
	"SECRET" VARCHAR2(32) CONSTRAINT "RHN_SERVER_SECRET_NN" NOT NULL ENABLE, 
	"CREATOR_ID" NUMBER, 
	"AUTO_DELIVER" CHAR(1) DEFAULT 'N' CONSTRAINT "RHN_SERVER_AUTO_DELIVER_NN" NOT NULL ENABLE, 
	"AUTO_UPDATE" CHAR(1) DEFAULT 'N' CONSTRAINT "RHN_SERVER_AUTO_UPDATE_NN" NOT NULL ENABLE, 
	"RUNNING_KERNEL" VARCHAR2(64), 
	"LAST_BOOT" NUMBER DEFAULT 0 CONSTRAINT "RHN_SERVER_LB_NN" NOT NULL ENABLE, 
	"PROVISION_STATE_ID" NUMBER, 
	"CHANNELS_CHANGED" DATE, 
	"CREATED" DATE DEFAULT (sysdate) CONSTRAINT "RHN_SERVER_CREATED_NN" NOT NULL ENABLE, 
	"MODIFIED" DATE DEFAULT (sysdate) CONSTRAINT "RHN_SERVER_MODIFIED_NN" NOT NULL ENABLE, 
	 CONSTRAINT "RHN_SERVER_DELIVER_CK" CHECK (auto_deliver in ('Y', 'N')) ENABLE, 
	 CONSTRAINT "RHN_SERVER_UPDATE_CK" CHECK (auto_update in ('Y', 'N')) ENABLE, 
	 CONSTRAINT "RHN_SERVER_ID_PK" PRIMARY KEY ("ID")
  USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS 
  STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 16 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
  TABLESPACE "DATA_TBS"  ENABLE, 
	 CONSTRAINT "RHN_SERVER_OID_FK" FOREIGN KEY ("ORG_ID")
	  REFERENCES "RHNSAT"."WEB_CUSTOMER" ("ID") ON DELETE CASCADE ENABLE, 
	 CONSTRAINT "RHN_SERVER_SAID_FK" FOREIGN KEY ("SERVER_ARCH_ID")
	  REFERENCES "RHNSAT"."RHNSERVERARCH" ("ID") ENABLE, 
	 CONSTRAINT "RHN_SERVER_CREATOR_FK" FOREIGN KEY ("CREATOR_ID")
	  REFERENCES "RHNSAT"."WEB_CONTACT" ("ID") ON DELETE SET NULL ENABLE, 
	 CONSTRAINT "RHN_SERVER_PSID_FK" FOREIGN KEY ("PROVISION_STATE_ID")
	  REFERENCES "RHNSAT"."RHNPROVISIONSTATE" ("ID") ENABLE
   ) PCTFREE 10 PCTUSED 40 INITRANS 32 MAXTRANS 255 NOCOMPRESS LOGGING
  STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 16 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
  TABLESPACE "DATA_TBS" 
 
/
