DB Admin-UTL_MAIL.SEND execution [message #271808] |
Wed, 03 October 2007 01:09 |
dba_giri
Messages: 26 Registered: July 2007 Location: Hyderabad
|
Junior Member |
|
|
Hi..,
I 've executed all the following scripts after created the DB(using DBCA) :
$oracle_home\rdbms\admin\catalog.sql at sysdba
$oracle_home\rdbms\admin\catproc.sql at sysdba
$oracle_home\sqlplus\admin\pupbld.sql at system user
Is there any scripts are required to execute for the following requirement
I 've tried to create a procedure as follows:
CREATE OR REPLACE PROCEDURE send_email AS
BEGIN
UTL_MAIL.SEND(sender => 'xxx@yahoo.com', recipients => 'xxx@yahoo.com', cc => 'xxx@yahoo.com', bcc => 'xxx@yahoo.com', subject => 'Testmail', message => 'Hello');
EXCEPTION
WHEN OTHERS THEN
-- dbms_output.put_line('Fehler');
raise_application_error(-20001,'The following error has occured: ' || sqlerrm);
END;
/
But, am getting the following error while creating it
PLS-00201: identifier 'UTL_MAIL.SEND' must be declared
Thanks in Advance
Giri K.Y.
|
|
|
|
Re: DB Admin-UTL_MAIL.SEND execution [message #271813 is a reply to message #271808] |
Wed, 03 October 2007 01:13 |
|
Michel Cadot
Messages: 68718 Registered: March 2007 Location: Saint-Maur, France, https...
|
Senior Member Account Moderator |
|
|
1/ Are you sure utl_mail is installed?
2/ Are you sure you get access to it directly or via PUBLIC?
3/ "WHEN OTHERS THEN raise_application_error(-20001,'The following error has occured: ' || sqlerrm);"
is quite stupid, remove this and you'll get the same thing plus the line where the error occured, information you lose with "when others"
Regards
Michel
|
|
|