declare post_time number(10); cvalue number(10,1); begin post_time :=1584072610; cvalue := 117; loop post_time := post_time -20; if post_time<1584071610 then exit; end if; insert into mg_data (plc_no,para_name,machine_no,dt_post_time,DATA,pcode) values (‘s7-1200-14‘,‘双拉机热固四区风机出风温度控制‘,‘P01‘,post_time,cvalue,‘M01‘); end loop; end;
原文:https://www.cnblogs.com/xifengmo/p/12487575.html