Application Development and Automation 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: 
Read only

Error while adding table entries to transport request

2,818

Hey Experts!

I currently got an error, so that I cannot add a new entry to a transport request programmatically.I am using two function TR_GET_REQUEST_TYPE and TR_REQUEST_CHOICE.I integrated them in the code as following
...
CALL FUNCTION 'TR_GET_REQUEST_TYPE'
  EXPORTING
    iv_pgmid          = 'R3TR'
    iv_object         = 'TABU'
    iv_obj_name       = 'ZSFLIGHT'
  IMPORTING
    ev_request_type   = lv_request_type
  EXCEPTIONS
    no_request_needed = 1
    invalid_object    = 2
    system_error      = 3.

CALL FUNCTION 'TR_REQUEST_CHOICE'
  EXPORTING
    iv_suppress_dialog = 'X'
    iv_request         = 'S4HK901283'
    iv_request_types   = lv_request_type
    it_e071k           = lt_e071k.
...

My workbeanch request

And the error message when running the report

I've already tried different transport request types. Unlocking the object doesn't help either.I don't know exactly where s the problem.

I would be very happy if someone has any idea.

Thanks 😛

1 ACCEPTED SOLUTION
Read only

OlegBash
Active Participant
2,417

The message that is outputed is about wrong transport type.

K - is for workbench request.
But it is seems that your table is client-dependent (standard SFLIGHT is client dependent). And in that case you need W-type of request (means Customizing Request).

You can check the IDs of request type in table E070 (field TRFUNCTION ).

So, you need another request type, S4HK901283 is not sufficient.

My sugestion:

1) for function TR_REQUEST_CHOICE do not provide IV_REQUEST_TYPES parameters (put here a space).
2) specify the number of request (S4HK901282), not a task (S4HK901283)

3 REPLIES 3
Read only

OlegBash
Active Participant
2,418

The message that is outputed is about wrong transport type.

K - is for workbench request.
But it is seems that your table is client-dependent (standard SFLIGHT is client dependent). And in that case you need W-type of request (means Customizing Request).

You can check the IDs of request type in table E070 (field TRFUNCTION ).

So, you need another request type, S4HK901283 is not sufficient.

My sugestion:

1) for function TR_REQUEST_CHOICE do not provide IV_REQUEST_TYPES parameters (put here a space).
2) specify the number of request (S4HK901282), not a task (S4HK901283)

Read only

0 Likes
2,417

Thank you Oleg, it works now

Read only

Former Member
0 Likes
2,417

Is there also a way to write the entires in the task (S4HK901283) instead of request (S4HK901282)?