oracle JOB运行时最小间隔时间是多少?
各位好:
写了一个存储过程如下:
create or replace procedure EPS_BID_UPDATE_CLOSE as
cursor t_sor is
select eap.time, eap.project_id from table_name eap;
begin
for v_sor in t_sor loop
if to_char(v_sor.Free_Bid_End, 'yyyy-mm-dd HH24:MI:SS') =
to_char(sysdate, 'yyyy-mm-dd HH24:MI:SS') then
update table_name ap
set ap.project_status = 4, ap.project_status = sysdate
where ap.project_status = 3
and ap.project_id = v_sor.project_id;
end if;
end loop;
commit;
end;
job设置如下:
begin
sys.dbms_job.submit(job => :job,
what => 'EPS_BID_UPDATE_START;',
next_date => to_date('18-04-2012 11:21:06', 'dd-mm-yyyy hh24:mi:ss'),
interval => 'SYSDATE+1/(60*24*60)');
commit;
end;
/
问题:发现job要隔5秒才执行一次,导存储过程中的检查总是延时,不能满足到某一秒时就去更新,各位有没有好办法,先谢谢了!
------解决方案--------------------
你这个语句已经是一秒钟跑一次了,问题是是你的job执行时间一秒钟能执行完么,可能是你的job执行的时间都不只1s造成的?