Skip to Content
avatar image
Former Member

RFC Fails in Background job via event BP_event_raise in badi .?

short-dump.pngshort-dump1.pngHi All,

I have a requirement to send GRN posting data after databse commit in ecc, to non ecc system, for which i have written a code in Badi MB_document_badi of method MB_DOCUMENT_UPDATE by calling event FM: BP_EVENT_RAISE passing event which was created in SM62 and this FM calls the background job which holds our RFC with destination... So here the problem is some time's RFC is success and some times it fails , i am getting sy-subrc = 1 as system failure. Attached the Short dump as well. at PI side they were not able to see any messages from ECC.

Kindly help me to fix the issue .

Thanks in advance.

Regards,

Ramu

short-dump.png (62.5 kB)
short-dump1.png (30.6 kB)
Add comment
10|10000 characters needed characters exceeded

  • As you didn't attach the short dump as a .txt zipped file, we can't see the contents of lv_msg1/lv_msg2 variables (probably they contain the text of the failure (system_failure = X message lv_msg1/lv_msg2))

  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Jan 29, 2017 at 09:40 AM

    Hi Sandra,

    Please find the attached Short dump .txt file.

    My situation here is strange that RFC executes some times and fails some times in background, when i. debug the background job using JDBG , RFC is getting response from other system. below is my RFC code.

    filling the all internal table and passing to RFC as shown below.

    this RFC is wriiten in one custom program , that program is assigned to event in BG job, this job is called via BP_event_raise , again this event is called in materila master MGA00001 exit via same FM bp_event_raise.

    CALL FUNCTION 'ZACC_M_I_MATERIAL_CREATEEXT' DESTINATION 'ECCTOPIRFCMAT'
    TABLES
    it_mat_date = lt_mat_data
    it_mat_sales = lt_sales
    it_mat_plant = lt_plant
    it_mat_taxcl = lt_taxcl
    it_status = it_status
    it_plant_sloc = lt_plant_sloc
    it_mat_desc = it_mat_desc
    it_mat_uom = it_mat_uom
    it_mat_upid1 = it_mat_upid1
    it_mat_upid2 = it_mat_upid2
    it_mat_upid3 = lt_upidskuloc
    EXCEPTIONS
    system_failure = 1
    communication_failure = 2
    OTHERS = 3.
    * To recieve Status from Pharmanet And Update in Sap Custom table
    IF sy-subrc EQ 0.
    COMMIT WORK.

    ........saving status from RFC i.e it_status in custom table.

    endif.

    Please help me to fix the issue.

    Thanks & Regards,

    Ramudump.txt

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Sandra Rossi

      Thanks for reply..:)

      our basis team and PI checked the Program ID , they are using different one for each communication channel.

      Even i checked the above SAP note , but here our RFC is synchronous and not related to any idoc. RFC is just picking the data and sending to third party.

      I still don't know what's the issue..as RFC fails and success Randomly.

      Thanks for help.

      Regards,

      Ramu

  • Jan 30, 2017 at 07:10 PM

    Looks like in the other system you are missing a function module... or a mis-spelling?

    |    CPI-C error text: "Bean ZACC_M_I_MATERIAL_CREATEEXT not found on host iplpid,                 |

    The very next line is

    ProgId =RFC_MAT: Object not found in lookup of ZACC_M_I_MATERIAL_CREA"

    which leads me to think that there maybe a limit on the size of the RFC name, up to 22 characters?

    Add comment
    10|10000 characters needed characters exceeded