读书人

施行出生日期变更记录写入

发布时间: 2012-07-04 19:33:54 作者: rapoo

执行出生日期变更记录写入

create or replace procedure do_updateis  OutputFile UTL_FILE.FILE_TYPE;  v_result varchar2(2048);  v_rfid_num number;  cursor r is    select distinct h.rfid as rfid from his_animal_info h;  thedata r%rowtype;beginv_rfid_num := 0;  open r;  loop    fetch r      into thedata;    v_rfid_num := v_rfid_num + 1;    OutputFile := utl_file.fopen('background_dump_dest','birthdayhis.log','a');    utl_file.putf(OutputFile,v_rfid_num);    utl_file.fflush(OutputFile);    utl_file.fclose(OutputFile);        get_BirthdayHis_By_RFID(thedata.rfid,v_result);    if (v_result is not null) then      update tbl_animal_info a         set a.birthday_his = v_result       where a.rfid = thedata.rfid;      commit;    end if;  end loop;  end;

读书人网 >其他数据库

热点推荐