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: 

Help in Call transaction

Former Member
0 Kudos

Hi all,

Iam using call transaction for RL12.

I have ITAB to process based on reason codes.

for ex if ITAB contains 4 records .

If first record processed unsuccessfully it automatically rejeting the next

3 records if they posts clean also.

Is there any way to do this and the program runs in background only.


  CALL TRANSACTION 'RL12'  USING    bdcdata
                           MODE     w_mode        "N"
                           UPDATE   w_update     "S"
                           MESSAGES INTO ts_mess_tab.

Any help will be appreciated.

Thanks

Sai.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

hi Sai,

Use Session Method( BDC_INSERT FM ) to catch the error records ...

Regards,

Santosh

5 REPLIES 5

Former Member
0 Kudos

hi Sai,

Use Session Method( BDC_INSERT FM ) to catch the error records ...

Regards,

Santosh

0 Kudos

Hi santosh,

I know what the error is.The problem is Iam not able to post the remaining records if first records get failed.

Thanks

Sai.

0 Kudos

Hi Sai,

I don't know what error the transaction creates but I guess, session method will resolve your problem.

Thanks

Viswa

0 Kudos

Hi all,

Thanks the problem is with the transaction rl12 itself.

Sai.

rahulkavuri
Active Contributor
0 Kudos

change the update mode ie w_update to 'A' and check it

try this and award points if found helpful


    call transaction 'FSP0' using it_bdcdata
                                  mode 'E'
                                  update 'A'
                                  messages into it_msgs.

    if not it_msgs[] is initial.

      loop at it_msgs.

        call function 'FORMAT_MESSAGE'
          exporting
            id        = it_msgs-msgid
            lang      = 'EN'
            no        = it_msgs-msgnr
            v1        = it_msgs-msgv1
            v2        = it_msgs-msgv2
            v3        = it_msgs-msgv3
            v4        = it_msgs-msgv4
          importing
            msg       = v_msg
          exceptions
            not_found = 1
            others    = 2.
        if sy-subrc <> 0.
          message id sy-msgid type sy-msgty number sy-msgno
                  with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        endif.
        write:/ v_msg.
      endloop.

Message was edited by:

Rahul Kavuri