2006 Sep 28 10:17 AM
I need to execute a FM in background. Can I use
CALL FUNCTION - IN BACKGROUND TASK for this purpose?
Regards,
Pooja
I need to execute a FM in background. Can I use
CALL FUNCTION - IN BACKGROUND TASK for this purpose?
Regards,
Pooja
2006 Sep 28 10:20 AM
Calling the FM in Backgroung marks a flags for that function module func to be run asynchronously. That is, it is not executed at once. Instead, the data passed using EXPORTING or TABLES is placed in a database table and the next COMMIT WORK executes it in another work process.
Regards,
Prakash.
2006 Sep 28 10:23 AM
for call function
IN UPDATE TASK is available. I am not sure about IN BACKGROUND TASK.
alternatively you can write it in a program and assign this to the background job.
Regards
srikanth
2006 Sep 28 10:24 AM
HI,
Function modules that you call using CALL FUNCTION ... IN BACKGROUND TASK DESTINATION are registered for background execution in another SAP System when the program reaches the next COMMIT WORK statement (using Remote Function Call). After the COMMIT WORK, the dialog process does not wait for these function modules to be executed (asynchronous update). All of the function modules that you register in this way are executed together in a single database LUW
if you want to run in normal background i mean the same system, then there is no need to write any thing, you can use call FUNCTION MODULE statment. but make sure that GUI_* and WS_* function modules do not work in background
Regards
Sudheer
2006 Sep 28 11:01 AM
I placed the break-point at Commit work and checked for the processes in sm50. When the execution atopped at the break-point I pressed F6 and then refreshed the work processes in sm50 but I was not able to find my backgroud process. I could only see the dialog process. Is it possible for me to debug this from process overview?
Regards,
Pooja
2006 Sep 28 12:08 PM
Hi,
probably (but u have to test this),is possible.
Just program an endless loop in your background task. Then in SM50 just debug the WP and u should enter in code of the endless loop.
for example.
data : x value '5'.
do.
if x = '10'.
exit.
endif.
enddo.
Thn in debug modify the value of the "x" to exit from the loop.
Hope it helps
Bye
Andrea
Pls reward if it helps
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |