insert into status (status_id,statustype,code,legacystatuscode,systemuser_id,timestamp,factorydescription)
values(seq_status.nextval, 'PL', '10', '', getminsystemuser(), getcurrentdatetime(), 'Proposal');
insert into status (status_id,statustype,code,legacystatuscode,systemuser_id,timestamp,factorydescription)
values(seq_status.nextval, 'PL', '20', '', getminsystemuser(), getcurrentdatetime(), 'In Progress');
insert into status (status_id,statustype,code,legacystatuscode,systemuser_id,timestamp,factorydescription)
values(seq_status.nextval, 'PL', '30', '', getminsystemuser(), getcurrentdatetime(), 'Confirmed');
insert into status (status_id,statustype,code,legacystatuscode,systemuser_id,timestamp,factorydescription)
values(seq_status.nextval, 'PL', '40', '', getminsystemuser(), getcurrentdatetime(), 'Cancelled');


insert into status_desc
          (status_id, language_id, description, systemuser_id, timestamp)
          select status_id,
                 getminlanguage(),
                 factorydescription,
                 systemuser_id,
                 timestamp
            from status
            where status.statustype = 'PL' and status.code in ('10','20','30');
