Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Pragma Restrict_references combined with NO_DATA_FOUND exception problem.
Hello,
The following package specification and body work fine until the exception handler is placed in. Is there any work around for this situation?
Thanks, John Duggan
/*===========================================================================*/
create or replace package sysuaf_pack as pragma restrict_references ( sysuaf_pack, wnds );
function UGROUP (IN_username in varchar2) RETURN varchar2; pragma restrict_references ( ugroup, wnds );
end sysuaf_pack;
/
/*===========================================================================*/
create or replace package body sysuaf_pack AS function UGROUP (IN_username in varchar2)
return VARCHAR2
is U_GROUP VARCHAR2(32);
begin
select (UPPER(UIC_GROUP)) INTO U_GROUP
FROM SYSUAF_TABLE WHERE UPPER(USERNAME) = UPPER(IN_USERNAME);
return ( U_GROUP );
exception
when no_data_found then Raise_application_error ( -100, 'Username does not exist' );end UGROUP;
John Duggan Internet : duggan_at_zonker.ecs.umass.edu Engineering Computer Services Univ. of Massachusetts Phone : (413) 545-1580 Amherst, MA 01003 ----------------------------------------------------------------------------Received on Tue Jul 07 1998 - 11:39:57 CDT