本人写了一个包怎么会报错,请高人指点!!

hnzpabc 2006-11-21 08:18:18
create or replace package show body is
declare
display varchar2(150):='this is test!';
procedure show_display()
is
begin
dbms_output.put_line(display);
end show_display;
end show;
...全文
198 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
kittykula 2006-11-30
  • 打赏
  • 举报
回复
定义 和 包体都帖出来呀
hnzpabc 2006-11-30
  • 打赏
  • 举报
回复
我后来改过,写了包定义和包体还报错!
icedut 2006-11-21
  • 打赏
  • 举报
回复
create or replace package body show is

display varchar2(150):='this is test!';
procedure show_display
is
begin
dbms_output.put_line(display);
end show_display;
end show;
icedut 2006-11-21
  • 打赏
  • 举报
回复
show body

位置反了
intotheheart 2006-11-21
  • 打赏
  • 举报
回复
不好意思,上面的错了
create or replace package show body is
procedure show_display() as
display varchar2(150);

begin
display :='this is test!';

dbms_output.put_line(display);
end show_display;
end show;
intotheheart 2006-11-21
  • 打赏
  • 举报
回复
create or replace package show body is
procedure show_display() as
display varchar2(150):='this is test!';
procedure show_display()
is
begin
dbms_output.put_line(display);
end show_display;
end show;

17,078

社区成员

发帖
与我相关
我的任务
社区描述
Oracle开发相关技术讨论
社区管理员
  • 开发
  • Lucifer三思而后行
  • 卖水果的net
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧