Skip to Content
0
Mar 09, 2020 at 09:08 PM

OData JSON Deserialize

979 Views Last edit Mar 09, 2020 at 09:12 PM 2 rev

Hi All,

I am trying to deserialize the simple JSON data using the class /UI2/CL_JSON. However the output internal table is initial. Can you please let me know what i am missing here.

    types:
      begin of ty_ekko,
        ebeln type ebeln,
        bukrs type bukrs,
        bstyp type bstyp,
        ktwrt type string,
      end of ty_ekko.
    data:
      lt_ekko type STANDARD TABLE OF ty_ekko.
   

    /ui2/cl_json=>deserialize( 
      EXPORTING 
        json = lv_json 
      CHANGING 
        data = lt_ekko ).
   check lt_ekko is not initial.

We're on SAP_ABA - 740 SP-Level - 0009

Thank you

Attachments

odata.png (19.0 kB)