Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

debugging

Former Member
0 Kudos

hi

i want the complete picture of debugging reports.

regards

ratna

1 ACCEPTED SOLUTION
7 REPLIES 7

anversha_s
Active Contributor
0 Kudos

hi,

<i>System Debugging</i>

If you set this option, the Debugger is also activated for system programs (programs with status S in their program attributes). When you save breakpoints, the System Debugging setting is also saved.

<i>Update Debugging</i>

Update function modules do not run in the same user session as the program that is currently running in the ABAP Debugger. These function modules are therefore not included in debugging. Only if you select the Update Debugging option can you display and debug them after the COMMIT WORK.

<i>Normal Debugging</i>

Normal debugging is the one we do it by the normal dynamic break points or by /H or by using stattic break points.

You can switch to diffferent debuggin modes while processing.

For debugging tutorial:

http://help.sap.com/saphelp_erp2005vp/helpdata/en/5a/4ed93f130f9215e10000000a155106/frameset.htm

http://www.sapdevelopment.co.uk/tips/debug/debughome.htm

http://www.sap-basis-abap.com/sapab002.htm

rgds

Anver

0 Kudos

HI,

again..some more info.

USE Breakpoints

it can be of different types.

Hard Break-Points : written in the code like

'Break-point 'Login- User Name''.

2)Soft Breakpoints

This is placed by placing the cursor at the line required by u and click the 'STOP' button or CntlShiftF12 in the std. menu

while executing your report the execution will stop at your break-point and will execute statements one by one

by using F5,F6,F7 & F8 function keys

3) By giving the command '/h' in the command box the debugging mode is opened from the starting of the program.

if u need further info u can go with these links

http://help.sap.com/saphelp_erp2005/helpdata/en/b3/d322540c3beb4ba53795784eebb680/frameset.htm

Debugging Document.

http://www.cba.nau.edu/haney-j/CIS497/Assignments/Debugging.doc

F5 is used to debug line by line code it will nevigate to each step wheter it is a method call or function it will go in side it.

F6 u will move line by line but does now enter inside any function call

F7 will return u to the upper level

Ex if u are inside any method that is called from any other main method u will move to the main method

Rgds

Anver

former_member758419
Active Participant
0 Kudos

Hi ratna,

Go through these threads for more information on debugging,

1)

2)

3)

4)

Regards,

Sachidanand.B

former_member283648
Participant
0 Kudos

First test your code with '/h' type in command window which shall take you to debug or by putting break points with F8. You test your program from code and then go to se30 performance analysis transaction and there you can know what are the drawbacks. Then go to SLIN transaction and do extended syntax check or from code in menu options where you have debugging -> extended check and the program id ready without error.

Tips by : Harichand Chandunair

Testing your code.

As mentioned above after doing syntax check and extended syntax check you have to create a TEST PLAN. You have to test all possible Postive & Negative test cases.

Test for division by zero if it involves calculation or code accordingly.

Try to test for field overflows. If it involves sap script or smart forms try to print outputs which have single page and also multiple page and which does not have any output at all.

Test by leaving all parameters in selection screen blank.

Test by entering wrong values in selection screen and display a pop-up if the user enters wrong selection screen values.

You can also do ABAP trace and SQL trace to make sure that your program is efficient.

Debugging code/program.

As mentioned above type /h in command line and try to execute the program. Another way is to set break-point at the function module or the required line and do single step execute or execute. Once you finished debugging, you can select Delete to clear all the break points.

Third option in certain cases is to check for sy-subrc <> 0 and proceed from there by making it 0 by updating the sy-subrc in the debug editor and see how the program behaves if the value is what you enterd in the debug screen. For certain case try to use WATCH POINT feature in debug editor.

Former Member
0 Kudos

HI,

Introduction: http://www.saplinks.net/index.php?option=com_content&task=view&id=24&Itemid=34

A <a href="http://www.sappro.com/downloads/Settings&SystemAreas.pdf">PDF file</a> to know knowledge about Debugging

Some more links:

http://www.sap-basis-abap.com/sapab002.htm

Debug Background Programs: http://www.sapdevelopment.co.uk/tips/debug/debug_backjob.htm

Debugger: http://help.sap.com/saphelp_nw2004s/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm

Regards

Sudheer