Application Development and Automation 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: 
Read only

how to debug function module in update task ?

Former Member
0 Likes
39,221

Hi ,

i have following code :

CALL FUNCTION 'ZSD_t_UPDATE' IN UPDATE TASK
             TABLES
                              it_xvbkd = xvbkd.

Inside this function module i have some code to debug . How can i debug it ?

I put the breakpoint in it but its not working .

It is triggered on save of a tcode .

Thanks and Regards .

1 ACCEPTED SOLUTION
Read only

Former Member
20,038

Hi,

It is not possible to debug in update task. If it is a zprogram, I suggest you call the function module without the update task, debug and see what is the problem, once it is resolved you call it again using update task.

Thanks

Mani

15 REPLIES 15
Read only

Former Member
0 Likes
20,038

jsut search with this text debug function module in update task

Read only

Former Member
20,038

hiii

Set a breakpoint just before the FM. When in debug mode select the

'update debugging' flag in the settings section then continue with

your debugging.

while debugging use F5 key to debug line by line ..... it will take you to source of that function module

Edited by: topppi on Mar 17, 2010 12:58 PM

Read only

0 Likes
20,038

hi i tried this but still its not working . The cursor didnt enter into the function module .

Read only

Former Member
0 Likes
20,038

Hi,

put the break point on the function module,

when the cursur come to function module press f5, the cursur will go inside the function module then u can debug the function module.

thanks

Read only

Mohamed_Mukhtar
Active Contributor
0 Likes
20,038

[debug function module in update task|http://www.sdn.sap.com/irj/scn/advancedsearch?query=debugfunctionmoduleinupdate+task#ABAP,%20General]

Read only

Former Member
20,039

Hi,

It is not possible to debug in update task. If it is a zprogram, I suggest you call the function module without the update task, debug and see what is the problem, once it is resolved you call it again using update task.

Thanks

Mani

Read only

former_member270407
Participant
0 Likes
20,038

hi ujjwal_dk,

you can debug it in update task..

first you should set update debugging active. you can do that from debugger screen with debug settings. than you say commit system closes normal debugging and will open for update debugging.

best regards.

Edited by: ERHAN YAZICI on Mar 17, 2010 3:40 PM

Read only

0 Likes
20,038

hi erhan ..........you say commit to system while debugging........whats that i didnt get....

Read only

0 Likes
20,038

hi,

for update task, you should commit system, then system will go update task .

best regards.

Read only

0 Likes
19,567

Hi, it is actually possible to debug FM called under IN UPDATE TASK. You have to put a debugger (if session breakpoint is not working then try external breakpoint) in the code inside the FM and enable update debugging in debugger settings, it will hit the piece of code.

Read only

Former Member
0 Likes
20,038

My home-grown method:

Set your breakpoint in the FM.

In your transaction, just before you press save, enter hobble mode in your command box with '/h'.

press save.

In your first debug screen, toggle settings>system debugging ON (NetWeaver Drop-down menu) or see previous notes for earlier WebAS versions.

Select continue (F8).

The program should then stop at your break-point in the FM.

Read only

kesavadas_thekkillath
Active Contributor
0 Likes
20,038

Please search before posting.

Keshav

Read only

Former Member
0 Likes
20,038

Thanks all for your reply .....

I removed the update task as suggested....

also changing settings for update task is also valuable....

Read only

Erol_CAGLAR
Participant
0 Likes
20,038

hi guy,

could you please click this link. After, you can debug it, easly.

https://saptechnical.com/Tutorials/ABAP/Debug/Index.htm

Read only

cdprasanna
Active Participant
0 Likes
20,038

Hi,

when a function module is called in update task it cannot be debugged normally because it wont run in same user session so in debugging mode goto menu

System-> update debugging. Switch it on to debug the FM.