ERPClimb logoERPClimb
Debugging
ABAP Developmentbeginner 7 min read

Debugging Part 2: ABAP Debugger Essentials

Preview · a free account unlocks the full lesson

Key takeaway

Use the ABAP debugger efficiently: starting it (/h, breakpoints in SE38/SE80/ADT), session vs external breakpoints, stepping (F5, F6, F7, F8), breakpoints at statements/messages/exceptions, changing variables, jumping, call stack, and the desktops and tools of the new debugger.

In this lessonShow sections

Visual overview

Debugging Part 2: ABAP Debugger Essentials — learning sheetFlow: Run any report with /h and step with F5/F6/F7/F8 → Set a breakpoint at statement MESSAGE and trigger an error message → Use the call stack to find the routine that decided to raise it. Key ideas: STARTING; STEPPING; DYNAMIC BREAKPOINTS; INSPECTING DATA. Watch out: Changing variable values in the debugger is fine in test systems but dangerous in production — it can create inconsistent data.ERPClimb.com / ABAP / LESSON 2/10 / LEARNING SHEETDebugging Part 2: ABAP Debugger Essentials1 · HOW IT FLOWS1Run any report with /hand step with F5/F6/F7/F82Set a breakpoint atstatement MESSAGE andtrigger an error message3Use the call stack tofind the routine thatdecided to raise it2 · KEY IDEAS EXPLAINEDStarting/h then execute → debugger starts at the nextdialog step.Session breakpoint (editor, Ctrl+Shift+F12 / stopsign): valid for your current logon session.SteppingF5 into routines, F6 over them, F7 back to caller,F8 to next breakpoint."Go to statement" (Shift+F12 on a line /"Goto statement") jumps withoutexecuting — use carefully.Dynamic BreakpointsBreakpoints → Breakpoint at → Statement: e.g.MESSAGE, COMMIT WORK, CALL FUNCTION, SELECT.Breakpoint at message: stops when messageID/number is issued — very effective for"where does this error come from?".Inspecting DataVariables desktop: values, change (pencil icon),structures, tables (Part 5).Call stack: which program/routine called thecurrent one — navigate up by double-click.3 · REMEMBER · WATCH OUTRememberStart: /h in the command field, breakpoints set in the editor(SE38/SE80/ADT), or BREAK-POINT in code (test only).Stepping: F5 single step (into), F6 execute (over), F7 return (out),F8 continue to next breakpoint.Breakpoints at statement (e.g. MESSAGE, SELECT, CALL FUNCTION), at amessage ID/number, or at an exception class find the right spot…!Watch outChanging variable values in thedebugger is fine in test systems butdangerous in production — it cancreate inconsistent data.4 · IN A REAL PROJECTA new developer tried to find where "Material is blocked" came from in a delivery by steppingthrough thousands of lines with F5. After three hours, a senior developer set "Breakpoint atmessage" for the message ID/number and reached the check in seconds, with the call stack showing the…Original ERPClimb learning sheet • Verify against your SAP release and edition

Explanation

Part 1 of this series defined the overall approach to debugging; this lesson covers the main tool itself — the ABAP Debugger.

You can start it by typing /h in the command field and then executing the next step, which starts the debugger at the next dialog step; by setting a session breakpoint in the editor (SE38, SE80, or ADT), using Ctrl+Shift+F12 or the stop-sign icon, which is valid only for your current logon session; by setting an external (user) breakpoint, valid for your user across all sessions, including RFC and HTTP calls, covered in Part 3; or, in test code only, by inserting a BREAK-POINT statement or BREAK <user> directly — checkpoint groups, using BREAK-POINT ID, should be used instead anywhere outside test code.

Stepping through code uses F5 to step into a routine, F6 to execute it and stay at the same level, F7 to return out of the current routine to its caller, and F8 to run on to the next breakpoint. "Go to statement" (Shift+F12 on a line, or the "Goto statement" command) jumps to a line without executing the code in between, and should be used carefully.

Free account

Create a free account to keep reading

You have read the opening of this lesson. A free ERPClimb account unlocks the rest of it, every other lesson and topic, and your learning history, so you can pick up exactly where you stopped. No card needed.

  • Full explanation
  • Code example
  • Real project scenario
  • Common mistakes
  • Best practices
  • Interview angle

One tap with Google works too. Every topic keeps its first lesson open to everyone.

Keep exploring

Referenced SAP objects

Reviewed reference pages for the objects this page mentions.

Check before use: lesson examples are educational, not a guarantee of correctness for your SAP edition or release. Sample code has not been executed on your SAP system. Confirm API availability, syntax, authorizations and business impact in an approved development or test environment.