表:

Oracle 学习----游标(使用无参光标cursor)

 

----游标-----------------------------

declare
  cursor tt is select name,sal from temp;
  vname temp.name%type;
  vsal temp.sal%type;
begin
  open tt;
  loop
    fetch tt into vname,vsal;
    exit when tt%notfound;
    dbms_output.put_line(vname||'-----'||vsal);
  end loop;
  close tt;
end;
/

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-11-22
  • 2021-04-17
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-11-29
  • 2022-12-23
  • 2022-12-23
  • 2021-08-29
  • 2022-12-23
  • 2022-12-23
  • 2021-06-06
相关资源
相似解决方案