Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Send mail from 8i SMTP package

Re: Send mail from 8i SMTP package

From: TimKArnold <timkarnold_at_aol.com>
Date: 27 Aug 2000 21:15:00 GMT
Message-ID: <20000827171500.11419.00000631@ng-fn1.aol.com>

If you can go to Metalink, do a search on utl_smtp. You need to install a few things. - there are 2 scripts and a jar.
Actually -
'class oracle/plsql/net/TCPConnection does not exist' indicates that the jar was NOT installed. I believe it is in the plsql directory.

email for more details if you cannot find it.

>Hi all!
>I'm trying to use the SMTP package to send email but have some problems. It
>is probably due to some bad environment variables or missing installed
>components. Running Oracle 8.1.6 on Solaris 2.6. The send_mail procedure is
>like (based on the example from Oracle documentation):
>
>PROCEDURE send_mail (sender IN VARCHAR2,
>recipient IN VARCHAR2,
>message IN VARCHAR2)
>IS
>mailhost VARCHAR2(30) := '<mailhost.mydomain.com>';
>mail_conn utl_smtp.connection;
>BEGIN
>mail_conn := utl_smtp.open_connection(mailhost, 25);
>utl_smtp.helo(mail_conn, mailhost);
>utl_smtp.mail(mail_conn, sender);
>utl_smtp.rcpt(mail_conn, recipient);
>utl_smtp.data(mail_conn, message);
>utl_smtp.quit(mail_conn);
>EXCEPTION
>WHEN OTHERS THEN
>-- Handle the error
>END;
>
>After calling this procedyre I'm receiving the following error:
>
>SQL> exec send_mail('test','test','Test')
>BEGIN send_mail('test','test','Test'); END;
>
>*
>ERROR at line 1:
>ORA-29540: class oracle/plsql/net/TCPConnection does not exist
>ORA-06512: at "SYS.UTL_TCP", line 533
>ORA-06512: at "SYS.UTL_TCP", line 199
>ORA-06512: at "SYS.UTL_SMTP", line 99
>ORA-06512: at "SYS.UTL_SMTP", line 121
>ORA-06512: at "OSNASS.SEND_MAIL", line 8
>ORA-06512: at line 1
>
>
>SQL>
>
>Can anyone point me in the right direction to solve this problem?
>
>--Peres--
Received on Sun Aug 27 2000 - 16:15:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US