2015 Jul 17 3:51 PM
Hi all,
I was hoping someone could clear up what is going on behind the scenes when I select a background job in SM37 and type JDBG in the command line. I'm still a bit new and didn't follow what was going on tracing it through the debugger.
To clarify I understand what the purpose of it is, but I don't like thinking of it as "I type that into the command line and then by magic I hit my breakpoint in my background process". I have not been able to find a lot of info about it other than a lot of threads stating that's how you debug background processes.
Thanks much,
-Chris
2015 Jul 17 9:28 PM
Hello
Note 573128 provides some information about debugging programs in background.
It provides the following information about JDBG:
1. Select a job in transaction SM37. In addition, set a breakpoint at the point in the source code that you want to analyze when debugging. In SM37, enter JDBG in the OK code field, and choose ENTER. The selected job is now started in debug mode, and the debugger initially stops in a system program. Choose F8 to continue the job up to the next breakpoint.
Caution: Although the job still appears in SM37 in the previous status after debugging, the entire job (or, more specifically, a copy of it) has run during debugging and possible database changes are effective as a result of the job.
BR
Caetano
2015 Jul 17 9:28 PM
Hello
Note 573128 provides some information about debugging programs in background.
It provides the following information about JDBG:
1. Select a job in transaction SM37. In addition, set a breakpoint at the point in the source code that you want to analyze when debugging. In SM37, enter JDBG in the OK code field, and choose ENTER. The selected job is now started in debug mode, and the debugger initially stops in a system program. Choose F8 to continue the job up to the next breakpoint.
Caution: Although the job still appears in SM37 in the previous status after debugging, the entire job (or, more specifically, a copy of it) has run during debugging and possible database changes are effective as a result of the job.
BR
Caetano
2015 Jul 20 2:45 AM
Hi Chris,
Just bear in mind, if you would like to debug the background job in SM37, the job should not execute immediately. You have to set the time delay for few seconds so that you have enough time to key the JDBG in command line for the debugging mode.
Thanks
Wong