/*****************************************************************************
*
* Filename         - $Workfile:   APPN_AMENDMENTS.sql  $
*
* Author           - Dave Banks
*
* Project Name     - UltraTrak Core 
*
* Source Code
* Identifier       - Database (Master Standby) 
*
* Design Spec
* Section          - 
*
* Contents         - Database script to create table APPN_AMENDMENTS
*
* Language         - Oracle SQL script      
*
* Classification   - Commercial In Confidence
*
*          (c) Ultra Electronics Limited, 2006
*
*****************************************************************************/

PROMPT Creating Table 'APPN_AMENDMENTS'
CREATE TABLE APPN_AMENDMENTS
 (ROW_CREATE_TIME DATE
 ,ROW_DATE_TIME DATE
 ,CUSER VARCHAR2(30)
 ,MUSER VARCHAR2(30)
 ,MTERM VARCHAR2(64)
 ,SOURCE VARCHAR2(8)
 ,TO_BE_ARCHIVED VARCHAR2(1)
 ,APPN_ROW_ID NUMBER(18) NOT NULL
 ,SYSTEM_ID NUMBER(4) DEFAULT 0 NOT NULL
 ,SEQ NUMBER(18,0) NOT NULL
 ,AMENDMENT LONG
 ,SESSION_ID NUMBER(18)
 ,TRANSACTION_ID VARCHAR2(146)
 )
 PCTUSED 90
 PCTFREE 5
 STORAGE
 (
   INITIAL 54525952
   NEXT 54525952
   PCTINCREASE 0
 ) TABLESPACE APPN_AMENDMENTS_TABLES
/

PROMPT Creating Primary Key on 'APPN_AMENDMENTS'
ALTER TABLE APPN_AMENDMENTS
 ADD (CONSTRAINT APPN_AMENDMENTS_PK PRIMARY KEY
  (SEQ)
 USING INDEX
 PCTFREE 5
 STORAGE
 (
   INITIAL 4000K
   NEXT 4000K
   PCTINCREASE 0
 ) TABLESPACE APPN_AMENDMENTS_IDXS)
/

