We will examine as to how to start the debugger and setting up breakpoints in SAP ABAP. The debugger can be started in the following ways.
Press /h before taking any action in the program By setting up a breakpoint and executing the program From the ABAP editor initial screen by pressing the debug button From the Object Navigator (SE80) Select a program and choose Test/Execute from the Development Object menu. The Choose Execution Type dialog box appears. Choose Debugging.
A maximum of 30 breakpoints can be set in the ABAP debugger. While editing the program a breakpoint can be set by clicking on the breakpoint icon (RED STOP) button in the menu bar. Or under the UTILITIES menu you navigate to BREAKPOINTS >>>>>>>>>>> DISPLAY, SET/DELETE, DELETE.
Break points can also be deleted using the same methods as mentioned above. Breakpoints thus created are user specific but they work across sessions for the same user. A break point can also be hard coded in the program Syntax BREAK-POINT, such breakpoints work across users. By using a breakpoint once you enter the debugger then the program can be examined in detail for removing the bugs.
Always use Pretty Printer and Extended Program Check before releasing the code.
Do not leave unused code in the program. Comment the code thoroughly. Align the comments and the Code. Follow the SAP Standards and SAP Best Practices guidelines. It’s a good practice to take a dump of the code on your local drive.