清除作业列表SQL

DELETE CM_JOB_SRC_LOG
WHERE job_id IN (select job_id from CM_JOB_LOG where job_status = '2000' and job_id in(
'20150919000114'
));

delete CM_JOB_STEP_LOG
where job_id in(select job_id from CM_JOB_LOG where job_status = '2000' and job_id in(
'20150919000114'
));

DELETE CM_JOB_STAT_LOG
WHERE job_id IN (select job_id from CM_JOB_LOG where job_status = '2000' and job_id in(
'20150919000114'
));

DELETE CM_JOB_LOG
WHERE job_status = '2000' and job_status = '2000' and job_id IN(
'20150919000114'
);

/* (job_status)
1000    正在执行中
2000    成功完成
3000    重启作业
4000    取消作业
9000    失败
*/

 

posted @ 2015-09-22 14:17  ArcerZhang  阅读(203)  评论(0编辑  收藏  举报