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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Send email whith oracle

Re: Send email whith oracle

From: PHernandez <phph109_at_yahoo.es>
Date: 28 Nov 2005 12:36:11 -0800
Message-ID: <1133210171.453765.190520@g14g2000cwa.googlegroups.com>


Andy Hassall ha escrito:

> On 28 Nov 2005 08:34:50 -0800, "Alen Cappelletti" <cocker_at_libero.it> wrote:
>
> >I write from Italy and with this procedure I want send a E-mail from
> >Oracle.
> >Ok, all works fine except the messagge body.
> >
> > v_header:= 'Date: '||TO_CHAR(SYSDATE,'dd Mon yy hh24:mi:ss')||crlf||
> > 'From: '||v_sender||''||crlf||
> > 'Subject: '||v_subject||crlf||
> > 'To: '||v_recipient||crlf||
> > 'CC: '||v_ccrecipient;
>
> OK, so v_header doesn't end in CRLF.
>
> [snip]
> > --
> > -- Write the header
> > --
> > utl_smtp.write_data(l_mail_conn, v_header);
>
> You write v_header, and you're still on the same line - no CRLF output yet.
>
> > utl_smtp.write_data(l_mail_conn, crlf||v_message ) ;
>
> You write out one CRLF, and then start the body; but you need another CRLF
> before the body, to terminate the header section with a blank line.
>
> The write_data line for v_header probably just needs "||crlf".

Likely, and when that is solved he'll need to actually add the cc's to the send list as well, the Cc header is not magic (and why have it there in case v_ccrecipient is null?).

--ph Received on Mon Nov 28 2005 - 14:36:11 CST

Original text of this message

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