4 Replies Latest reply on Mar 14, 2013 12:45 PM by VC

    How to stop APEX_MAIL.SEND procedure

    Robert
      Dear All,

      I have created an email functionality in APEX 3.0.1.00.08 using the following procedures:

      DB VERSION: 10.2.0.4.0

      1. APEX_MAIL.SEND(
      P_TO => P_TO,
      P_FROM => v_from,--p_from,
      P_BODY => p_mailbody,
      P_BODY_HTML => p_mailbody_html,
      P_SUBJ => p_subject
      );


      2. wwv_flow_mail.push_queue

      I am using the the above mentioned two procedures in a page process. In the page process I defined two cursors:


      1. cursor: I select the email adresses (P_TO).


      2. cursor: I define the number of emails that should be sent to the selected email adresses. At this step we commeted an error: our cursor delevers us more than 1.000.000 records.

      So we have been reciewing anormus number of emails for 12 hours without end.

      Is there any way to stop/empty the procedures?

      Thank you!

      Regards,

      Robert
        • 1. Re: How to stop APEX_MAIL.SEND procedure
          VC
          Robert wrote:
          Dear All,

          I have created an email functionality in APEX 3.0.1.00.08 using the following procedures:

          DB VERSION: 10.2.0.4.0

          1. APEX_MAIL.SEND(
          P_TO => P_TO,
          P_FROM => v_from,--p_from,
          P_BODY => p_mailbody,
          P_BODY_HTML => p_mailbody_html,
          P_SUBJ => p_subject
          );


          2. wwv_flow_mail.push_queue

          I am using the the above mentioned two procedures in a page process. In the page process I defined two cursors:


          1. cursor: I select the email adresses (P_TO).


          2. cursor: I define the number of emails that should be sent to the selected email adresses. At this step we commeted an error: our cursor delevers us more than 1.000.000 records.

          So we have been reciewing anormus number of emails for 12 hours without end.

          Is there any way to stop/empty the procedures?
          Identify the oracle session and kill it..hurry up!

          Vikram
          • 2. Re: How to stop APEX_MAIL.SEND procedure
            Robert
            Hi,

            thank you for your rapid answer!

            we identified the session and we marked it for "killing" on database level (SQL Developer).

            Furthermore we also killed the session on oparating system level with the statment: "kill -9 >spid<".

            Problem solved! Thank you!

            Reagards, Robert
            • 3. Re: How to stop APEX_MAIL.SEND procedure
              joelkallman-Oracle
              Hi Robert,

              FYI - Beginning in APEX 4.2, there is now a per-workspace limit for emails. The default is a 1,000 per workspace in a rolling 24-hour period. You should consider upgrading sometime (as APEX 3.0.1 is no longer supported).

              Joel
              • 4. Re: How to stop APEX_MAIL.SEND procedure
                VC
                Joel,

                Nice one I wasn't aware of this parameter WORKSPACE_EMAIL_MAXIMUM