on 2022 Mar 21 12:28 PM
Hello experts,
I have a question concerning read entities statement. I was able to reproduce my problem with the ‘Demo Flight Reference Scenario (TX managed)’ on ABAP trial account.
I focused on CDS-Consumption view /DMO/C_TRAVEL_PROCESSOR_M which has some fields of associated views (e.g. AgencyName read from CDS-View /DMO/I_Agency)
The above-mentioned Consumption-View is exposed via Service-Definition /DMO/UI_TRAVEL_Processor_M. The preview of the corresponding Service-Binding gives me the ability to display the attribute AgencyName:
Now I try to read the data of the Consumption-View (better of the corresponding behavior ‘/DMO/C_Travel_Processor_M’) via EML:
READ ENTITIES OF /DMO/C_Travel_Processor_M
ENTITY TravelProcessor
ALL FIELDS WITH VALUE #( ( %pky-TravelID = '00000001' ) ( %pky-TravelID = '00000002' ) )
RESULT DATA(gt_result).
I am quite surprised to find only the exposed attributes of the projected Interface-View ‘/DMO/I_Travel_M’ inside the derived type. The additional field AgencyName is not part of the derived type.
Am I doing something wrong or is my expectation of having the additional fields inside the derived type wrong?
Could someone please shed some light on this problem?
Many thanks in advance.
Best regards
Chris
Request clarification before answering.
Better to go with option #1.
I see SAP Demo Apps also using same solution.
please see below documentation.
https://help.sap.com/viewer/923180ddb98240829d935862025004d6/Cloud/en-US/fed023a4ed9d4d7494e5c853b11...
READ ENTITIES OF /DMO/I_Travel_M IN LOCAL MODE
ENTITY travel
ALL FIELDS WITH CORRESPONDING #( keys )
RESULT DATA(travel_read_result)
FAILED failed.
READ ENTITIES OF /DMO/I_Travel_M IN LOCAL MODE
ENTITY travel BY \_booking
ALL FIELDS WITH CORRESPONDING #( travel_read_result )
RESULT DATA(book_read_result).
READ ENTITIES OF /DMO/I_Travel_M IN LOCAL MODE
ENTITY booking BY \_booksupplement
ALL FIELDS WITH CORRESPONDING #( book_read_result )
RESULT DATA(booksuppl_read_result).
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
63 | |
8 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.