cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Callback function module

Former Member
0 Likes
2,178

Hi Experts,

What are callback function modules?

Why do we use them and in what scenarios are we required to use them?

What is their purpose and how are they helpful?

Can anybody explain with an example.

Regards,

Sangeeta.

View Entire Topic
Former Member
0 Likes

Hi Sangeeta,

CALLBACK modules basically return the u2018oldu2019 and u2018newu2019 memory of a dataset after an operation and thus give you a snapshot of what data changed in the process. They find use in event triggers, or to define a reaction based on some processing done in the transaction.

E.g : say you want to send an Email to a supervisor everytime a user changes the BP name. The only way you can know if the BP name has changed is by comparing the database for BUT000-NAME_FIRST and BUT000-NAME_LAST between before and after the operation. To do this, you can just call module BUP_MEMORY_BUT000_CALLBACK, or BUPA_GENERAL_CALLBACK. This returns the BUT000 state before and after in 2 tables - ET_BUT000_OLD and ET_BUT000_NEW. So you can easily compare the contents and react accordingly.

The most classic use of Callback modules is in Data Exchange. The callback modules help the application decide what data has changed, and thus, what must be sent over to the other connected systems.

Hope this helps you !

Cheers,

Rishu.