Hi Folks,
another question regarding the code within a simple transformation, where I am transforming a deep ABAP structure into a JSON string.
The parent ABAP structure contains, as well as some string fields, an embedded flat structure:
ACCESS_TOKEN Types ZDE_ACCESS_TOKEN STRING USER_GSTIN Types ZDE_USER_GSTIN STRING DATA_SOURCE Types ZDE_DATA_SOURCE STRING TRANSACTION_DETAILS Types ZSTY_TRANS_DETAILSThe embedded "transaction_details" structure contains string fields:
SUPPLY_TYPE Types ZDE_SUPPLY_TYPE STRING CHARGE_TYPE Types ZDE_CHARGE_TYPE STRINGThis is what the critical part of my transformation code (in XSLT) looks like:
<str name="data_source">
<tt:value ref="einvoice_request.data_source"/>
</str>
<transaction_details>
<object>
<str name="supply_type">
<tt:value ref="einvoice_request.transaction_details.supply_type"/>
</str>
When debugging, as soon as the transformation hits the "transaction_details" element, it fails. Obviously the code is incorrect, but I don't know how to declare the "transaction_details" element as an embedded flat structure.
Thanks for reading,
JM
At the risk of sounding patronising (which I don't mean to be), I hope @sandra.rossi reads this.