Ask Me Help Desk

Ask Me Help Desk (https://www.askmehelpdesk.com/forum.php)
-   Other Compiled Languages (https://www.askmehelpdesk.com/forumdisplay.php?f=466)
-   -   How I can send email through Oracle 6i Forms? (https://www.askmehelpdesk.com/showthread.php?t=120325)

  • Aug 17, 2007, 12:19 AM
    sunilkjose
    How I can send ane email through oracle 6i forms ?
    How I can send ane email through oracle 6i forms ?
  • Oct 13, 2009, 09:59 PM
    whfamily2006
    basically, create the stuff below.
    create a button on the form, call send_mail..

    you will need to know you mailhost

    code..

    tkyte@TKYTE816> create or replace
    2 PROCEDURE send_mail (p_sender IN VARCHAR2,
    3 p_recipient IN VARCHAR2,
    4 p_message IN VARCHAR2)
    5 as
    6 l_mailhost VARCHAR2(255) := 'aria.us.oracle.com';
    7 l_mail_conn utl_smtp.connection;
    8 BEGIN
    9 l_mail_conn := utl_smtp.open_connection(l_mailhost, 25);
    10 utl_smtp.helo(l_mail_conn, l_mailhost);
    11 utl_smtp.mail(l_mail_conn, p_sender);
    12 utl_smtp.rcpt(l_mail_conn, p_recipient);
    13 utl_smtp.open_data(l_mail_conn );
    14 utl_smtp.write_data(l_mail_conn, p_message);
    15 utl_smtp.close_data(l_mail_conn );
    16 utl_smtp.quit(l_mail_conn);
    17 end;
    18 /
    Procedure created.

    tkyte@TKYTE816> begin
    2 send_mail( '[email protected]',
    3 '[email protected]',
    4 'Hello Tom' );
    5 end;
    6 /

    PL/SQL procedure successfully completed.
  • Nov 1, 2011, 11:09 AM
    aciesler
    I get the email, however, my ISP requires authentication and I am having difficulty figuring out how to authenticate with an SMTP server before sending the email. Help?

  • All times are GMT -7. The time now is 05:48 PM.