
PROMPT Creating table REASON_FOR_LOSS_CODE

CREATE TABLE REASON_FOR_LOSS_CODE ( 
   RL_CODE                       VARCHAR2 (3) not null,
   DESCRIPTION                   VARCHAR2 (100),
   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
);

alter table reason_for_loss_code add ( constraint reason_for_loss_code_pk primary key (appn_row_id) using index tablespace &1._indexes);

alter table reason_for_loss_code add ( constraint reason_for_loss_code_uk1 unique (rl_code) using index tablespace &1._indexes);

COMMENT ON TABLE REASON_FOR_LOSS_CODE IS 'This table contains a list of reason for loss codes';

COMMENT ON COLUMN REASON_FOR_LOSS_CODE.DESCRIPTION IS  'Description of the code';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.RL_CODE IS  'Reason for loss code';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.APPN_ROW_ID IS 'Unique sequence number for this row';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.ROW_CREATE_TIME IS 'The time the row was created';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.ROW_DATE_TIME IS 'The time the row was last modified';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.CUSER IS 'The user who created the row';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.MUSER IS 'The user who last modified the row';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.MTERM IS 'The terminal from which the last modifcation to this row was made';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.SYSTEM_ID IS 'The system identifier';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.SOURCE IS 'The process that last amended this row ';
COMMENT ON COLUMN REASON_FOR_LOSS_CODE.TO_BE_ARCHIVED IS 'Indicates that this row is to be archived or has been archived';
