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

Problems adding object to Transport request via FM TR_REQUEST_CHOICE.

Former Member
0 Likes
2,434

Hi.

Iu2019m having some problems with a function module to a table entries to a transport request.

I want to put all table entries of a specified table (ZTRANSPORT_TEST) into a transport request by calling a function module.

Iu2019m filling the structures e071 with programId u201CR3TRu201D and ObjectType u201CTABUu201D but I get the following error:

Object R3TR, referred to by the object key, does not exist

Message no. TR600

Diagnosis

The object keys of the request/task cannot be edited because the object (R3TR) which is referenced by the object key is not in the request, nor is it going to be added to the request.

What am I doing wrong?

Here the source code:

REPORT  z_test_add_to_request.

PARAMETERS: p_req TYPE trkorr. "W22K900273

DATA: it_e071     TYPE tr_objects,
      it_e071k    TYPE tr_keys,
      wa_e071     TYPE e071,
      wa_e071k    TYPE e071k.

* Create Object entry.
wa_e071-trkorr    = p_req.
wa_e071-pgmid     = 'R3TR'.
wa_e071-object    = 'TABU'.
wa_e071-obj_name  = 'ZTRANSPORT_TEST'.

* Create Key entry.
wa_e071k-trkorr   = p_req.
wa_e071k-pgmid    = 'R3TR'.
wa_e071k-object   = 'TABU'.
wa_e071k-objname = 'ZTRANSPORT_TEST'.
wa_e071k-tabkey   = '*'.

* Fill tables.
APPEND wa_e071  TO it_e071.
APPEND wa_e071k TO it_e071k.

* Add table entries to the transport.
CALL FUNCTION 'TR_REQUEST_CHOICE'
  EXPORTING
    iv_suppress_dialog   = 'X'
    iv_request_types     = '*'
    iv_request           = p_req
    it_e071              = it_e071
    it_e071k             = it_e071k
    iv_lock_objects      = ' '
    iv_with_error_log    = 'X'
    iv_no_owner_check    = 'X'
  EXCEPTIONS
    invalid_request      = 1
    invalid_request_type = 2
    user_not_owner       = 3
    no_objects_appended  = 4
    enqueue_error        = 5
    cancelled_by_user    = 6
    recursive_call       = 7
    OTHERS               = 8.

IF sy-subrc <> 0.
  MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
          WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.

Regards Michael

Hi.

Iu2019m having some problems with a function module to a table entries to a transport request.

I want to put all table entries of a specified table (ZTRANSPORT_TEST) into a transport request by calling a function module.

Iu2019m filling the structures e071 with programId u201CR3TRu201D and ObjectType u201CTABUu201D but I get the following error:

Object R3TR, referred to by the object key, does not exist

Message no. TR600

Diagnosis

The object keys of the request/task cannot be edited because the object (R3TR) which is referenced by the object key is not in the request, nor is it going to be added to the request.

What am I doing wrong?

Here the source code:

REPORT  z_test_add_to_request.

PARAMETERS: p_req TYPE trkorr. "W22K900273

DATA: it_e071     TYPE tr_objects,
      it_e071k    TYPE tr_keys,
      wa_e071     TYPE e071,
      wa_e071k    TYPE e071k.

* Create Object entry.
wa_e071-trkorr    = p_req.
wa_e071-pgmid     = 'R3TR'.
wa_e071-object    = 'TABU'.
wa_e071-obj_name  = 'ZTRANSPORT_TEST'.

* Create Key entry.
wa_e071k-trkorr   = p_req.
wa_e071k-pgmid    = 'R3TR'.
wa_e071k-object   = 'TABU'.
wa_e071k-objname = 'ZTRANSPORT_TEST'.
wa_e071k-tabkey   = '*'.

* Fill tables.
APPEND wa_e071  TO it_e071.
APPEND wa_e071k TO it_e071k.

* Add table entries to the transport.
CALL FUNCTION 'TR_REQUEST_CHOICE'
  EXPORTING
    iv_suppress_dialog   = 'X'
    iv_request_types     = '*'
    iv_request           = p_req
    it_e071              = it_e071
    it_e071k             = it_e071k
    iv_lock_objects      = ' '
    iv_with_error_log    = 'X'
    iv_no_owner_check    = 'X'
  EXCEPTIONS
    invalid_request      = 1
    invalid_request_type = 2
    user_not_owner       = 3
    no_objects_appended  = 4
    enqueue_error        = 5
    cancelled_by_user    = 6
    recursive_call       = 7
    OTHERS               = 8.

IF sy-subrc <> 0.
  MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
          WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.

Regards Michael

2 REPLIES 2
Read only

Former Member
0 Likes
1,445

Hi.

Found the problem. I missed to fill the entries:

wa_e071-objfunc     = 'K'.

wa_e071k-mastertype = wa_e071-object.
wa_e071k-mastername = wa_e071-obj_name.

Regards Michael.

Read only

0 Likes
1,259

Hi

if the object type is form, what we have to pass at  wa_e071-objfunc

harika_2378_1-1727243113750.png

harika_2378_2-1727243180212.png

harika_2378_0-1727243048683.png

passing these inputes to the fm and when I am trying to execute getting the below one

harika_2378_3-1727242765353.png

Pls help anyone to resolve this.