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

FM in Update Mode

Former Member
0 Likes
3,833

Dear All,

Can anyone tell me about, what is the use of craeting Function Module in Update Mode?

Thanks in advance.

Kind Regards,

Prasad

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
2,635

Hi,

The update function module is for execution in update task.

It is not executed immediatley..It will be triggered when a subsequent commit work is executed..

If it fails..You can use SM13 to view the update terminations..

difference..You cannot call normal function module IN UPDATE TASK...The update modules is not remotely callable..

Regards,

Satish

3 REPLIES 3
Read only

Former Member
0 Likes
2,636

Hi,

The update function module is for execution in update task.

It is not executed immediatley..It will be triggered when a subsequent commit work is executed..

If it fails..You can use SM13 to view the update terminations..

difference..You cannot call normal function module IN UPDATE TASK...The update modules is not remotely callable..

Regards,

Satish

Read only

Former Member
0 Likes
2,635

Hi,

1.if you want to use committ work or roll back ,then go for update mode.

2.Calling a FM in Update Task is one of the bundling techniques used in ABAP to avail functionality provided by SAP Update System. Here all database updates are processed at the end of the SAP LUW in contrast to normal FM call where the database updates are done and commited at the time of call (Database LUW). It is necessary to bundle all your database updates in an SAP LUW e.g. all database updates in a transaction (like VA01) should be bundled. Almost all standard SAP transactions use bundling techniques.

This technique separates the dialog process and update process. The dialog part of the transaction can span more than one screen(one dialog step) and can be processsed by more than one dialog work process. A work process is released when the dialog step changes (screen changes) and the work process sends a database commit (called Implicit Database LUW). So with each screen change there is a database commit and database remains in consistent state.

Now when using bundling technique, when a COMMIT WORK is encountered, system ends the dialog process with a dialog work porcess and starts the update process using an update work process.

The dialog step containing the COMMIT WORK is considerd as the last dialog step of the transaction and all the update function modules are processed now in the last dialog step by the update work process though they were called earlier during the earlier dialog steps.

It is necessary to create update FMs to take advantage of this technique. The update FM is created FM by setting the Update moduleradiobutton in the Attributes tab in SE37.

In a normal FM call, if there are database updates (UPDATE, INSERT, MODIFY, DELETE) than database is commited after the FM processing is over as the FM starts its own Database LUW and ends it too.

Regards,

Shiva.

Read only

Former Member
0 Likes
2,635

Many thanks for ur kind help.

Thanks a lot once again.

Best Regards,

Prasad