`
memorymyann
  • 浏览: 266789 次
  • 性别: Icon_minigender_1
  • 来自: 上海
社区版块
存档分类
最新评论

oracle存储过程

阅读更多

一个简单的存储过程样例,为免忘记,写在这里:

create or replace procedure clean_userunsubscription(day_p in number) as
day_v number(2);
last_v date;
begin
    day_v := day_p;
    last_v := sysdate - day_p;
    delete from tbl_ss_user_unsubscription where endtime < last_v;
    commit;
exception
    when others then
    rollback;       
end;
/

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics