2008 Oct 20 11:08 AM
H all,
I have developed a program which is scheduled to run every hour. The program is used to send mail to the user based on some conditions. ie
SELECT SINGLE ukurs INTO ukurs FROM tcurr WHERE kurst = 'M'
AND fcurr = 'USD'
AND tcurr = 'INR'
AND gdatu = sgdatu.
IF ukurs IS INITIAL.
*& logic to send mail to external user with the message
'Please Maintain Exchange Rate Table'
else.
*& If the exchange rate is maintained the user shud get the mail showing the exchange rate maintained.
endif.
My problem is that since the job is scheduled through SM36/SM37, How can I control the mail once the exchange rate is maintained in the table? I want to show the exchange rate that is maintained and then after no mail should be sent.
Pls guide.
Regards,
Anu.
H all,
I have developed a program which is scheduled to run every hour. The program is used to send mail to the user based on some conditions. ie
SELECT SINGLE ukurs INTO ukurs FROM tcurr WHERE kurst = 'M'
AND fcurr = 'USD'
AND tcurr = 'INR'
AND gdatu = sgdatu.
IF ukurs IS INITIAL.
*& logic to send mail to external user with the message
'Please Maintain Exchange Rate Table'
else.
*& If the exchange rate is maintained the user shud get the mail showing the exchange rate maintained.
endif.
My problem is that since the job is scheduled through SM36/SM37, How can I control the mail once the exchange rate is maintained in the table? I want to show the exchange rate that is maintained and then after no mail should be sent.
Pls guide.
Regards,
Anu.
2008 Oct 20 11:12 AM
I think You will have to maintain another table for this.
regards,
Advait
Edited by: Advait Gode on Oct 20, 2008 12:13 PM
2008 Oct 20 11:15 AM
One way is to check date / time when exchange rate was maintained, if that is less than last Job run date / time, you may assume that mail for exchange rate for that particular record would have been send in last job.
Regards,
Mohaiyuddin
2008 Oct 20 11:25 AM
Thanks for you reply, but the exchange rate is maintained in TCURR where no field captures the time or date when the exchange rate is getting updated...so is this possible?
Thanks and Regards,
Anu.
2008 Oct 20 11:33 AM
If Log Change is active in your system (you can check with sys administrator / basis ) and TCURR has "Log data changes" ticked in your technical setting, there is chance to get date / time of each updated / inserted record from Change Log tables. [Tcode - SCU3]...
Otherwise, you will need to create custom table for the same.
Regards,
Mohaiyuddin
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |