
-- DROP TABLE tl_work_flow_stage;




CREATE TABLE tl_work_flow_stage (
    object_id number(12) NOT NULL ,
    object_last_updated_date date DEFAULT SYSDATE NOT NULL ,
    object_created_date date DEFAULT SYSDATE NOT NULL
    ,
    name clob NOT NULL,
    use_messaging char(1) NULL,
    stage_type varchar2(200) NOT NULL,
    sort_order number(12) NOT NULL,
    auto_progress char(1) NULL,
    withdrawal_message_id number(12)  NULL,
    work_flow_template_id number(12)  NOT NULL
    );



ALTER TABLE tl_work_flow_stage ADD    
    CONSTRAINT PK_tl_work_flow_stage PRIMARY KEY 
    (
        object_id
    ) ;
    
    
    
    CREATE INDEX idx_tl_work_flow_stage_work_flow_template_id 
    ON tl_work_flow_stage (work_flow_template_id);
