Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

PLS-00307: too many declarations of 'SEND' match this call

AquaNX4Jun 22 2017 — edited Jun 22 2017

I'm trying to compile a PL/SQL anonymous block on one of my application's page but I am getting the following error:

PLS-00307: too many declarations of 'SEND' match this call

I've tried to research the error but cannot come up with a solution.  Any advice here?

This is the anonymous block:

CREATE OR REPLACE PROCEDURE auto_EMAIL

AS

   l_vw_jobs      my_vw%rowtype;

   v_htmlbody     CLOB;

   l_body_text    CLOB;

   l_id           NUMBER;

   v_to           CLOB;

   v_cc           CLOB;

BEGIN

SELECT    *

   INTO l_vw_jobs

   FROM my_vw

   WHERE ID = :p1_id;

SELECT    get_job_request_distro(:p1_id)

   INTO v_to

   FROM dual;

SELECT    get_job_request_distro_s(:p1_id)

   INTO v_cc

   FROM dual;

l_body_text := 'Plain text version';

v_htmlbody := '<HTML> <BODY>';  

  v_htmlbody := v_htmlbody

      || '<span style="font-family: consolas,Arial, Helvetica, sans-serif;font-size:11px;font-weight:bold">

            Good Day:<br><br>

            Message here:<br><br></span>';

   -- Prepare HTML Table Header

   v_htmlbody := v_htmlbody || '<table cellpadding="8";style="border-collapse: collapse; border: 1px solid black"><tbody>';

   v_htmlbody := v_htmlbody

      || '<tr><th style="font-family: consolas,TW Cen MT,Tahoma; font-size: 13px; background-color: #eef; border: 1px solid black">'

      || 'Requestor'

      || '</th>'

      || '<td style="white-space:nowrap;text-align:LEFT;font-family: consolas,TW Cen MT,Tahoma;border: 1px solid black; font-size: 11px; ">'

      || l_vw_jobs."Requestor"

      || '</td></tr>'

      || '<tr><th style="font-family: consolas,TW Cen MT,Tahoma; font-size: 13px; background-color: #eef; border: 1px solid black">'

      || 'Priority'

      || '</th>'

      || '<td style="white-space:nowrap;text-align:LEFT;font-family: consolas,TW Cen MT,Tahoma;border: 1px solid black; font-size: 11px;COLOR:RED; ">'

      || l_vw_jobs.PRIORITY

      || '</td></tr>'

      || '<tr><th style="font-family: consolas,TW Cen MT,Tahoma; font-size: 13px; background-color: #eef; border: 1px solid black">'

      || 'Allocated Hours'

      || '</th>'

      || '<td style="white-space:nowrap;font-family: consolas,TW Cen MT,Tahoma;border: 1px solid black; font-size: 11px; ">'

      || l_vw_jobs."Approver Allocated Hours"

      || '</td></tr>'

      || '<tr><th style="font-family: consolas,TW Cen MT,Tahoma; font-size: 13px; background-color: #eef; border: 1px solid black">'

      || 'Request Description'

      || '</th>'

      || '<td style="font-family: consolas,TW Cen MT,Tahoma;border: 1px solid black; font-size: 11px; ">'

      || l_vw_jobs."Request Description"

      || '</td></tr>';

     

  

   -- End HTML Table

  

  

   v_htmlbody := v_htmlbody || '</tbody></table><br>';

   v_htmlbody := v_htmlbody

      || '<span style="font-family: consolas,Arial, Helvetica, sans-serif;font-size:11px;font-weight:bold">

v/r<br>

                                       Email Signature <br>

                                       </span>

                                       ';

   -- End Header and Body

   v_htmlbody := v_htmlbody || '</BODY> </HTML>';

l_id := apex_mail.send(

      p_to           => v_to,

      p_cc           => v_cc,

      p_from         => 'somewhere',

      p_body         => l_body_text,

      p_body_html    => v_htmlbody,

      p_subj         => 'something');

     

        FOR c1 IN (SELECT attach_filename, attach_data, attach_mimetype

        FROM my_table

        WHERE ID = :p1_id) loop

       

            if c1.attach_filename is not null then

            apex_mail.add_attachment(

            p_mail_id    => l_id,

            p_attachment => c1.attach_data,

            p_filename   => c1.attach_filename,

            p_mime_type  => c1.attach_mimetype);

       

        end if;

        END loop;

       

    COMMIT;

   BEGIN

      apex_mail.push_queue (p_smtp_hostname   => 'xx.xx.xx.xx',

                            p_smtp_portno     => '25');

   END;

END auto_EMAIL;

This post has been answered by Etbin on Jun 22 2017
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 20 2017
Added on Jun 22 2017
7 comments
9,418 views