Wednesday, June 27, 2018

Deleting BADI Implementation and Class


  • Take the class name and go to SXC_CLASS
  • Give class name in IMP_CLASS
  • Get the implementation name IMP_NAME
    • Description of the class should give the implementation name. Checking the table is to make sure that the description is not changed.
  • Now go to se19
    • Give the implementation name IMP_NAME ->Delete
    • It will give a pop up to delete the class also.. You can delete the class here or again go to SE24 and delete the class.




Error
MOVE_CAST_ERROR
CX_SY_MOVE_CAST_ERROR
CL_EX_RSU5_SAPI_BADI==========CP
Solution
This will happen if the class is deleted when the enhancement is still present. Follow above steps to delete it and it should be fine.

Since this dump occurs after you delete, try creating the class again (with no code) and delete it properly.

Friday, June 1, 2018

Remote Function Module


Using Remote FM to trigger jobs in another system.

In this scenario, we will see how to trigger a functional module from BW to ECC.

1) Create Function Module in ECC - SE37
   Go to Attributes -> Make it Remote-Enabled Module
   Add parameters - The attributes need to be 'Pass Value' - Check the  
   box

2) Write code as any other ABAP Code.

3) In BW, create a program in SE38
   Below is some sample code
   parameters: p_rfcdest like rfcdisplay-rfcdest,
               p_value type CHAR3.
   call function 'ZECC_FM_IN_ECC' destination p_rfcdest
     exporting
       value = p_value


You can also trigger an event from one system to another using Remote Function Modules. Below are the steps.

1) Create an event in SM62

2) Create a job in SM36 and give the start parameter as the event.

3) Create program in BW. You can use FM 'RSSM_EVENT_RAISE' which is a standard  Remote enable FM.