After i have analyzed a background job’s attributes in SM37, i discovered that there is ABAP report and variant of the report in step data.
SAP does not provide a functionality to prevent dublicate background job scheduling. Therefore if you schedule a background job more frequent than the run time of background job, there will be surely dublicate jobs running parallely. In order to prevent this i have written a check routine inside of my ABAP program that stops the program when there is an already running job with the same name.
As mentioned in earlier submit report versions post you can make use of SUBMIT statement from your ABAP program in order to schedule any other ABAP program in background. However recently i have met a situation where user wants to decide the date and frequency of this background program. Therefore you may want to populate some fields in JOB_CLOSE of scheduling background job using an interface. BP_START_DATE_EDITOR provides this interface by collecting required information from the user.
Recently i had a requirement to trigger a background job from my custom program. Background job had a standard SAP report as step and report was processing a business logic. After this business process has been completed after execution of background job, system creates an application log in SM37. I needed to read this log , because some times background job was failing because of a business problem like lock situations. I have used BP_JOBLOG_READ to achieve this requirement. You can adapt below code according to your requirement.
When you call a list screen your report generates a downloadable report after execution. This report seems as a spool list if you run your program in background. There are two ways to generate a list screen. First one is using WRITE command and the second one is using REUSE_ALV_GRID_DISPLAY which serves to output internal table as an ALV list.
Sometimes we need extra search criteria for job selection. For this purpose we use ‘Extended Job Selection’ button in SM37. If you want to directly go into this functionality you can use SM37C. This transaction helps us to search jobs according to many criteria like start date/time, ABAP program name, periods , time interval which the jobs was active and so on.
In EWM Documents are one of the main objects which we always need to access through our custom developments. There are different types of Documents which most of them you can already […]
There was a standard process in our system which sends a text as the body of a mail, after a certain operation is completed. For this program a change had been done so that the program could send a custom SMARTFORM as a PDF attachment beside to the text body. This change had been done as a repair in a program. So far so good, everything was working fine.