Quantcast
Channel: SCN : All Content - ABAP Development
Viewing all articles
Browse latest Browse all 8332

call function in update task empty variables error

$
0
0

Hello,

 

I'm experiencing a weird error while using the addition "In update task".

 

My Scenario is the following:

 

Use the bapi_goodsmvt_create -> if there are no errors, fill some values and call my function and then commit everything.

 

The problem is, when the function runs in update task, all import parameters are empty!

 

Also, this only happens in the following code structure

 

CALLMETHOD run_migo(IMPORTING bapireturn = t_bapireturn).

IF t_bapireturn ISINITIAL.

  CALLMETHOD save_custom_tables."this runs my function 'IN UPDATE TASK'

  CALLFUNCTION'BAPI_TRANSACTION_COMMIT'

    EXPORTING

      wait = 'X'.

ENDIF.

 

 

if I commit inside the method SAVE_CUSTOM_TABLES, the data is passed normally to the function, if I commit like the code above, everything is empty.


Viewing all articles
Browse latest Browse all 8332

Trending Articles