Starting the debugger and the kinds of breakpoint, reading short dumps, message types, and the performance tools.
Contents
How well you use the debugger largely determines how productive ABAP development is. Where standard source is readable, it also lets you follow what SAP itself is doing.
Starting the debugger
Method
How
Breakpoint
Set a stop position in the source
/h in the command field
The debugger starts at the next statement
BREAK-POINT statement
Written in the source; never transport it
BREAK username
Stops only for that user
Run from SE38
Choose debug execution
Kinds of breakpoint
Kind
Behaviour
Session
Active for the logon session; the usual choice
External
Also stops in RFC and web processing
Statement
Stops on a specific ABAP statement, such as MESSAGE
Exception
Stops when a given exception class is raised
Method or subroutine
Stops on entry to a processing block
A statement breakpoint on MESSAGE is the quickest way to find where an unexplained error message is being issued.
Watchpoints
A watchpoint halts when a variable changes, optionally only when it reaches a given value — the way to catch one specific iteration inside a large loop.
Short dumps
What to read in ST22
Section
Content
Runtime error
The category of failure
Error analysis
What went wrong
Source code extract
The failing line and its surroundings
User and terminal
Who ran it
Active calls
The call stack
Frequent runtime errors
Error
Cause
CX_SY_CONVERSION_NO_NUMBER
Arithmetic on text that is not numeric
CX_SY_ZERODIVIDE
Division by zero
CX_SY_ITAB_LINE_NOT_FOUND
A table expression found no row
CX_SY_REF_IS_INITIAL
Calling a method on an initial reference
TIME_OUT
Runtime exceeded the dialog limit
DBIF_RSQL_SQL_ERROR
The database rejected the statement
Messages
Message types
Type
Meaning
Behaviour
S
Success
Status bar; processing continues
I
Information
Dialog box; continue on OK
W
Warning
Return to the screen; can proceed
E
Error
Return to the screen; must be corrected
A
Abend
Terminates processing
X
Exit
Produces a short dump
Performance tools
Code
Purpose
ST05
SQL trace — statements and their durations
SAT (formerly SE30)
ABAP runtime analysis
ST22
Short dump list and detail
SM50 / SM66
Process monitoring; find long runners
SLG1
Application log
ST12
Combined SQL and ABAP trace
Check your understanding
Test what you just read.
Quiz 1
Which transaction code is used to view ABAP short dumps (runtime errors)?
Quiz 2
Which debugger action advances to the next line without entering subroutines or methods?
Quiz 3
ABAP supports TRY~CATCH~ENDTRY exception handling.
Quiz 4
Which message type displays an error message in the MESSAGE statement?
Quiz 5
Entering /h in the command field activates the debugger.
Quiz 6
What prefix do ABAP exception class names start with?
Hear when the paid version launches
A paid version is in preparation, with no ads, saved learning progress and many more practice questions. Leave your email and you will be told when it launches.
Your email address is used only to announce the paid version.