cancel
Showing results for 
Search instead for 
Did you mean: 

How to send a deep structure into an action of an ODATA v4?

Kinsbrunner
Active Contributor
0 Kudos

Hi all,

I am writing this as a continuation of what andre.fischer wrote on this blog regarding the issues that exist for working with Deep Updates in ODATA v4.

I was definitelly able to sort this out by using a similar approach to the one he said by using a custom HTTP Handler which was intercepting the PATCH request and was achieving what I wanted.

However, I'd like to have all the things together within RAP and saw a message from Andre stating that he was going to try to provide detail about an alternative method which consisted on using Actions. I have defined my RAP action and have while using a plain abstract entity as a parameter. However, I am currently experiencing issues when trying to convert this plain abstract entity into a deep one with a simple second level (both abstract entities joined through an association). When triggering the POST for the action, I am now getting an error due to malformed syntax on the payload but this is well written and validated.

Has anyone experienced something similar?

andre.fischer do you have any advice on how to build the abstract entity that needs to be used as the structure for simulating the deep update through a custom action? Was this the way you were thinking as a workaround for the deep update issue?

Advices are very welcome!

Regards.

Alejandro.

View Entire Topic
Andre_Fischer
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Alejandro,

yes, indeed, that was the workaround I was thinking of.

I assume that you might have not used the keyword "deep" and the appropriate mappings as described in the ABAP key word documentation:

RAP action - ABAP Keyword Documentation (sap.com)

// mapping: table 

action a2_from_deep_table deep table parameter DEMO_CDS_ABSTRACT_ROOT;

But this is just guessing since you have not share any source code snippet ;-).

Kind regards,

Andre

Ramjee_korada
Active Contributor
0 Kudos

Hi andre.fischer

Could you please check and let us know if the feature is yet to be delivered in BTP - ABAP Environment ? I see that metadata and service binding are failing that deep table parameter.

Please see question with screen shots.

RAP : Error for Action with Deep Table Parameter - Metadata and Service Binding fails

Best wishes,

Ramjee Korada