cancel
Showing results for 
Search instead for 
Did you mean: 

RPTARQEMAIL is sending e-mails 2 times

Former Member
0 Kudos

We are starting RPTARQEMAIL and the other needed programs with a job every 15 minutes. The last month everything works fine. Since about 1 month every mail is sending 2 times.

1. The job runs the first time and RPTARQEMAIL is selecting the right requests to the right period. The RPTARQEMAIL reads the table PTREQ_BATCH perfect and is setting the PTREQ_BATCH perfect. The e-mails will be send.

2. When the job runs a second time RPTARQEMAIL read the requests again. The form is starting with the right period, but the answer includes the requests of the last job. The e-mails for a old request will be send a second time.

3. With the next job the requests from the first job are not more selected.

Thanks for help.

View Entire Topic
former_member276898
Discoverer

Hi SDN colleagues,

I know that this post is quite old and marked as "Assumed answered", but since so far no solution was posted, and after dealing with a similar issue for a long time, I figured I'd post my solution for future reference:

we experienced the same problem at a customer system: about 3/4 of the mails sent through RPTARQMAIL and RPTCORMAIL (mostly those to the requestor) were sent twice, on two successive program runs. Our POST and MAIL programs were initially scheduled to run every 15 minutes, as two sequential steps on the same job, but even a change to 1 hour did not solve the problem.

After a while we noticed a certain pattern: requests with doubled mails were those which change to Status Posted (as visible in transaction PTCOR/PTARQ) occurred at the exact time that was marked as "Last run" of the email program on table PTREQ_BATCH. This meant that the items were valid for two successive intervals, thus the doubled mails.

To solve the issue we separated the POST and MAIL steps in two different jobs that run with a time lag of a couple of minutes. Worked like a charm!