Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

error: PL/SQL statement ignored

691672Mar 19 2009 — edited Mar 19 2009
In the code below i am getting 3 errors:
a. PL/SQL statement ignored
b. PLS-00201
c. PL/SQL: ORA-00904 : invalid identifier

please help. thank you


=========================================
Package body:
=========================================
create or replace package BODY manage_students
as
procedure find_sname
(i_student_id IN student.student_id%TYPE,
o_first_name OUT student.first_name%TYPE,
o_last_name OUT student.last_name%TYPE)
IS
v_student_id student.student_id%TYPE;
BEGIN
select first_name, last_name
into o_first_name, o_last_name
from student
where student_id = i_student_id;
exception
when others
then
DBMS_OUTPUT.PUT_LINE('Error in finding student_id: '||v_student_id);
end find_sname;

function id_is_good
(i_student_id in student.student_id%TYPE)
return BOOLEAN
IS
v_id_cnt number;
begin
select count(*)
into v_in_cnt
from student
where student_id = i_student_id;
return 1 = v_id_cnt;
EXCEPTION
when others then
return FALSE;
end id_is_good;
END manage_students;

/

=========================
Package specification:
=========================
set serveroutput on
create or replace package manage_students
as
procedure find_sname
(i_student_id IN student.student_id%TYPE,
o_first_name OUT student.first_name%TYPE,
o_last_name OUT student.last_name%TYPE
);
function id_is_good
(i_student_id IN student.student_id%TYPE)
RETURN BOOLEAN;
END manage_students;

/

Edited by: happyjoshua777@gmail.com on Mar 19, 2009 6:03 AM

Edited by: happyjoshua777@gmail.com on Mar 19, 2009 6:03 AM
This post has been answered by SomeoneElse on Mar 19 2009
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 16 2009
Added on Mar 19 2009
6 comments
1,460 views