日期:2014-05-17  浏览次数:20803 次

各位大侠帮我看看,存储过程调包报错

这个是包头
create or replace package More_student
as
function getPwdById(names in student.loginname%type) return varchar2;
end more_student;



create or replace package body More_student

as
function getPwdById(names student.loginname%type) return varchar2
  is
begin
  return 'select s.loginpwd from student s where LoginName='''+names+'''';
end;
end More_student;



存储过程如下:
create or replace procedure Gettests
(LoginName in student.loginname%type)
as
begin
  more_student.getPwdById(LoginName);
end;
end Gettests;



错误信息:

PLS-00103:出现符号“END”

对oracle不是很熟,希望大家帮忙解决一下! 谢谢了!

------解决方案--------------------
SQL code

create or replace procedure Gettests
(LoginName in student.loginname%type)
as
begin
  more_student.getPwdById(LoginName);
--end;多了个,去掉
end Gettests;

------解决方案--------------------
探讨

SQL code

create or replace procedure Gettests
(LoginName in student.loginname%type)
as
begin
more_student.getPwdById(LoginName);
--end;多了个,去掉
end Gettests;

------解决方案--------------------
同意一楼的看法,去掉end;或者end Gettests;都可以