2011 Sep 15 4:30 PM
Hello Experts,
Need your help with a tricky issue in our system.
We have an output type defined to send invoice output as email. Lately we have an issue with this.
If we trigger the output in foreground it works fine. But when we create the invoices from batchjob it is triggering multiple emails for the same invoice. When we check the output in invoice it was triggered only once. Even in NAST also we have only one entry for these invoices. This issue is happening randomly not for all the invoices created through batch.
To nailed down the issue we have added code to update the application log in the output program. It wil update the application log in SLG1 transaction when ever the output program was called. Surprisingly even for the cases where the mail triggered multiple times we have only one entry in the log. It means even though the mail sent multiple times, it is calling the output porgam only once.
We are not able to replicate this issue even after mulitple trails.
Please suggest how we can find the root cause for this issue. All the ideas are welcome.
Thanks,
Srini
2011 Sep 15 4:36 PM
Hi
How do you send the mail?
Do you use OPEN_FORM or by yourself?
Check if you set a number of copy greater than 1 (if you use OPEN_FORM)
Max
2011 Sep 15 4:53 PM
We are using a Smartform here. Converting it into PDF and sending it as mail attachment using the function module 'SO_DOCUMENT_SEND_API1'.
Output in the invoice had number of copies as one only and print program is also trying to send it only once.
Thanks,
Srini
2011 Sep 15 4:57 PM
Hi
The problem could be in SO_DOCUMENT_SEND_API1 or in the program called to send the mail
SO_DOCUMENT_SEND_API1 places the mail in SOST (how many messages you can see there?)
If you see only one message the problem could be in the program to send the mail
Max
2011 Sep 15 5:00 PM
If the issue is with the program or function module it should be there for all the invoices. This issue is happening for only few invoices that to in background only.
Everything is working fine even If we retrigger the output in the foreground for same invoice which sent multiple email in batch.
2011 Sep 15 5:04 PM
When I speak about fm SO_DOCUMENT_SEND_API1, I mean how you call it
Max