‎2007 Aug 08 8:24 AM
I have written the FM Call function 'COMMITROUTINE' in update task.
but this FM is not getting triggered when some commit happens. In all, this FM is not commiting tha data in the table.
CALL FUNCTION 'COMMITROUTINE' IN UPDATE TASK
EXPORTING
lt_dfkkbrlevyrec = lt_dfkkbrlevyrec
and the
What is missing in it?
Regards,
Seema Dadhwal.
‎2007 Aug 08 8:34 AM
Hi,
if you want to call your FM when a commit happens you should write a routine which is called upon commit and this routine will call your fm.
e.g
form call_my_fm .
CALL FUNCTION 'COMMITROUTINE' IN UPDATE TASK
EXPORTING
lt_dfkkbrlevyrec = lt_dfkkbrlevyrec
endform.
perform call_my_fm on commit.
......
......
commit work. " now your routine will be called
Kostas
‎2007 Aug 08 10:02 AM
what will be the attrite of that Function Module.
Is it normal Fm or update module?
Thanks,
Seema
‎2007 Aug 08 10:05 AM
You should check the update module radiobutton in FM attributes
Kostas
‎2007 Aug 08 10:19 AM
Hi,
Go to the attribute tab of the fn module. there check update module radio button.
also check the start immediate radio button or Immediate start , No restart
thn call the fn module
CALL FUNCTION 'COMMITROUTINE' IN UPDATE TASK
EXPORTING
lt_dfkkbrlevyrec = lt_dfkkbrlevyrec.
COMMIT WORK.
Regards,
Nikhil.
‎2007 Aug 08 12:02 PM
Hi
if you did the settings for Update module , also check for the following statements.
SAP help documentation for in update task says:
'While an update function module is processed in an update work process, you are not allowed to execute the statements SUBMIT, CALL DIALOG, CALL SCREEN, CALL TRANSACTION, COMMIT WORK, ROLLBACK WORK and all other statements that provoke a database commit'.
Check have you used any statements which provokes a database commit?
Regards,
Shrinivas