Oracle-定时任务

PLSQL->新建->命令行窗口

--存储过程
create or replace procedure prd_remove_error_data
AS
BEGIN
UPDATE  rpt_person_area T SET T.AREA_MC='长江大桥开发区' WHERE T.AREA_MC='大桥开发区';
commit;
end prd_remove_error_data;


VARIABLE jobno number;
begin
  sys.dbms_job.submit(job => :jobno,
                      what => 'prd_remove_error_data();',
                      next_date => to_date('22-07-2016 07:15:00', 'dd-mm-yyyy hh24:mi:ss'),
                      interval => 'sysdate+1');
  commit;
end;
/

 

posted @ 2016-07-26 14:52  伍叶春  阅读(124)  评论(0编辑  收藏  举报