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

Update table

Former Member
0 Likes
493

Guys,

I am doing an update on a dbase table in a user exit. After updating the table I am calling the table in my main program by calling the PBO of the main screen.

But i observed that the table updation is happening only after a while, as a result the old values are retrieved when I reload the screen. Is there any way I can ensure that the table gets updated before my screen call?

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
471

hi,

Write COMMIT WORK in your User Exit After the Updation Logic.

It will Perform Updation at that time.

Regards

Sumit Agarwal

4 REPLIES 4
Read only

Former Member
0 Likes
471

Try to use WAIT Statement after your updation of records in table.

Thanks

Sudharshan

Read only

Former Member
0 Likes
472

hi,

Write COMMIT WORK in your User Exit After the Updation Logic.

It will Perform Updation at that time.

Regards

Sumit Agarwal

Read only

Former Member
0 Likes
471

Hi,

Commit work will solve your problem but use it with caution. As it is not recommended to be used in user exit.

Read only

former_member217544
Active Contributor
0 Likes
471

Hi,

COMMIT statement will resolve the issue else you can use the following BAPI.

CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'

EXPORTING

WAIT = 'X'

IMPORTING

RETURN = RETURN.

Return will show the success or failure of the commit statement.

If that is still not getting updated then try using the WAIT statement separately.

WAIT UP TO 2 SECONDS.

Hope this will solve the issue.

Regards,

Swarna Munukoti.