Skip to Content

changeSet_process question

Hi experts.


for update my odata v2 model. I fill changing table CT_CHANGESET_RESPONSE(fill entity_data from my internal table for each entry ) by example in class /IWBEP/CL_MGW_RT_SFLIGHT.

And when I do :

"success": function(d, r) {
var resp = d.__batchResponses[0];



In success method i am getting empty response(No content).

Maybe i need to do something else? Maybe i need fill headers in CT_CHANGESET_RESPONSE?

2l9uk.png (10.6 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Nov 22, 2017 at 04:07 PM

    Hey Alex,

    I'm assuming you got all your connections set and you have established a CRUD able channel.

    Given all that, based on the example method you provided, /IWBEP/IF_MGW_APPL_SRV_RUNTIME~CHANGESET_PROCESS, are you changing the CT_CHANGESET_RESPONSE parameter? As you already suspected it will contain the response (look at the structure that contains the fields: operation_no, entity_data etc, clearly an indication for a response change).

    Furthermore, in the private method HANDLE_CHANGESET_CREATES you can see the call to method COPY_DATA_TO_REF and above it the comment states that we set the response data and later append it to the response table, i.e. CT_CHANGESET_RESPONSE.

    Bottom line, return values in CT_CHANGESET_RESPONSE based on what you changed and you will see them in the success method.

    Add comment
    10|10000 characters needed characters exceeded

  • Nov 23, 2017 at 01:54 AM

    Hello, Iftan.

    Thanks for answer, but I append data in CT_CHANGESET_RESPONSE and in success method response is empty

    LOOP AT lt_patch_info INTO ls_patch_info.
        ASSIGN ct_changeset_response[ operation_no = ls_changeset_request-operation_no ] TO FIELD-SYMBOL(<fs_resp>).
        CHECK <fs_resp> IS ASSIGNED.
        ls_changeset_request = VALUE #( it_changeset_request[ operation_no = ls_patch_info-operation_no ]  OPTIONAL ).
        CHECK NOT ls_changeset_request IS INITIAL.
        ls_changeset_request-entry_provider->read_entry_data( IMPORTING es_data = ls_entity ).
        SELECT SINGLE * INTO @DATA(ls_user)
           FROM zvdfi_cds_users
           WHERE class = @ls_patch_info-usergroup AND mandt = '301'.
          ls_user-bukrs = ls_patch_info-bukrs.
           copy_data_to_ref( EXPORTING is_data = ls_user CHANGING cr_data = <fs_resp>-entity_data ).

    Add comment
    10|10000 characters needed characters exceeded

    • I don't understand, what is activation.

      But breakpoint in back-end work and abap debugger stand in

      /IWBEP/IF_MGW_APPL_SRV_RUNTIME~CHANGESET_PROCESS and in debugger i can see than table

      CT_CHANGESET_RESPONSE has entries at the end of method.

      Maybe i need fill headers in CT_CHANGESET_RESPONSE?