Application Development 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: 

Dump on write to message table

Former Member
0 Kudos

HI all,

i am doing compare with 2 tables and if in table it_userid there is a user that is

not in table et_emp i want to return this user that doesn't exist to table et_return

i get dump ,what i miss here.

i build message class for it and i want add the user to the specific message.

what i do is like that

LOOP AT it_userid ASSIGNING <ls_userid>.
        READ TABLE et_emp ASSIGNING <ls_d> WITH KEY userid = <ls_userid>-userid.
        IF sy-subrc NE 0.
          CALL FUNCTION 'BALW_BAPIRETURN_GET2'
            EXPORTING
              type   = 'E'
              cl     = 'CM_DT'  "message class that i build in se91
              number = '25'
              par1   = <ls_userid>-userid
            IMPORTING
              return = et_return.

Regards

Joy

1 ACCEPTED SOLUTION

Former Member
0 Kudos

you should have told what the Runtime error is. anyways, assuming it sud be the following..

Function modules are generally lil picky about the import variables.

declare

data : v_type type BAPIRETURN-TYPE,

v_cl type SY-MSGID,

v_number type SY-MSGNO.

and pass your values to this variables and then pass those variables to the FM.

2 REPLIES 2

Former Member
0 Kudos

you should have told what the Runtime error is. anyways, assuming it sud be the following..

Function modules are generally lil picky about the import variables.

declare

data : v_type type BAPIRETURN-TYPE,

v_cl type SY-MSGID,

v_number type SY-MSGNO.

and pass your values to this variables and then pass those variables to the FM.

huseyindereli
Active Contributor
0 Kudos

Hi,

It's hard tho understand the problem. But try to pass FM parameters with the exact type.

DATA : 
lv_TYPE LIKE  BAPIRETURN-TYPE ,
lv_CL LIKE  SY-MSGID ,
lv_NUMBER LIKE  SY-MSGNO ,
lv_PAR1 LIKE  SY-MSGV1 .