CREATE TABLE hrt_channel_messages (
    MESSAGE_ID               NUMBER(18, 0) ,
    MESSAGE_FROM             VARCHAR2(4000),
    MESSAGE_TO               NUMBER(18, 0)     NOT NULL,
    PERSON_ID                NUMBER(18, 0) ,
    EMAIL_FROM               VARCHAR2(4000),
    EMAIL_TO                 VARCHAR2(4000),
    EMAIL_CC                 VARCHAR2(4000),
    EMAIL_BCC                VARCHAR2(4000),
    EMAIL_DATE               DATE              NOT NULL,
    EMAIL_SUBJECT            VARCHAR2(4000),
    EMAIL_BODY               CLOB          ,
    TAGS                     VARCHAR2(4000),
    STAR                     VARCHAR2(120) ,
    HASHTAGS                 VARCHAR2(4000),
    STATUS                   VARCHAR2(120) ,
    BUSINESS_GROUP_ID        NUMBER(18, 0) ,
    SOURCE                   VARCHAR2(4000),
    ATTACHMENT_EXIST_FLAG    VARCHAR2(120) ,
    OBJECT_VERSION_NUMBER    NUMBER(9, 0)      NOT NULL,
    CREATED_BY               VARCHAR2(256)     NOT NULL,
    CREATION_DATE            TIMESTAMP(6)      NOT NULL,
    LAST_UPDATED_BY          VARCHAR2(256)     NOT NULL,
    LAST_UPDATE_DATE         TIMESTAMP(6)      NOT NULL,
    LAST_UPDATE_LOGIN        VARCHAR2(128) ,
    MESSAGE_ID               NUMBER(18, 0) ,
    MESSAGE_FROM             VARCHAR2(4000),
    MESSAGE_TO               NUMBER(18, 0)     NOT NULL,
    PERSON_ID                NUMBER(18, 0) ,
    EMAIL_FROM               VARCHAR2(4000),
    EMAIL_TO                 VARCHAR2(4000),
    EMAIL_CC                 VARCHAR2(4000),
    EMAIL_BCC                VARCHAR2(4000),
    EMAIL_DATE               DATE              NOT NULL,
    EMAIL_SUBJECT            VARCHAR2(4000),
    EMAIL_BODY               CLOB          ,
    TAGS                     VARCHAR2(4000),
    STAR                     VARCHAR2(120) ,
    HASHTAGS                 VARCHAR2(4000),
    STATUS                   VARCHAR2(120) ,
    BUSINESS_GROUP_ID        NUMBER(18, 0) ,
    SOURCE                   VARCHAR2(4000),
    ATTACHMENT_EXIST_FLAG    VARCHAR2(120) ,
    OBJECT_VERSION_NUMBER    NUMBER(9, 0)      NOT NULL,
    CREATED_BY               VARCHAR2(256)     NOT NULL,
    CREATION_DATE            TIMESTAMP(6)      NOT NULL,
    LAST_UPDATED_BY          VARCHAR2(256)     NOT NULL,
    LAST_UPDATE_DATE         TIMESTAMP(6)      NOT NULL,
    LAST_UPDATE_LOGIN        VARCHAR2(128) ,
    CONSTRAINT pk_hrt_channel_messages PRIMARY KEY (MESSAGE_ID, BUSINESS_GROUP_ID, MESSAGE_ID, BUSINESS_GROUP_ID)
);
