cancel
Showing results for 
Search instead for 
Did you mean: 

OData Service Using BOR RFC

TanmayVerma
Active Participant
0 Kudos

Hi Experts,

I was looking into the possibility of using RFC / BOR for creating Entities in Odata service as well as using map to data source functionality however i am facing issues passing tables as input to RFC.

I am using BAPI_MATERIAL_SAVDATA for entity creation and mapping.

I came across very useful blogs but the blogs provide example using simple entities without navigation.

http://scn.sap.com/community/developer-center/netweaver-gateway/blog/2013/12/22/steps-in-creating-ga...

http://scn.sap.com/community/developer-center/netweaver-gateway/blog/2013/12/22/detailed-step-by-ste...

I have few questions:

While creating entities using RFC BAPI_MATERIAL_SAVEDATA we selected all the structures as well as tables, as a result of which a singe complex entity (Material_Details) was created which was a combination of all structures. Also different entities were created for each tables. Below is the screenshot of same:

Entity Material_Details is the entity having all structure fields of BAPI (import structures).

For all Table parametes of BAPI separate entites have been created.

Now when i do map to data source in Service Implementation for Material_Details i can only map the fields of this entity. If i want to also map the fields in other entities so that we can pass table parameters to BAPI in single call how can we achieve that ?

Here during mapping is there a way we can map fields of other entities linked through navigation ?

Or if we map the fields in create method for each entity separately then during material create how can send data and pass all tables and structures in RFC call at one go, at the call of create_entity set method of main entity.

~Tanmay

Accepted Solutions (0)

Answers (2)

Answers (2)

TanmayVerma
Active Participant
0 Kudos

Hi Syam,

Thanks for the reply. We are using the Deep Entity Method. We wanted to check if there is a way to achieve it though mapping. Did a lot of research and found that it would not suffice the requirement. Thanks for your inputs.

~Tanmay

SyambabuAllu
Contributor
0 Kudos

Hi Tanmay,

For the above requirement does not suite the BOR/RFC Mapping with multiple entities for create_entity method.

Solution : You have to go with code-based implementation and redefine the Create_deep_entity method in data provider class and implement the method with your RFC/BAPI ex: BAPI_MATERIAL_SAVEDATA

Please refer the below link for your requirment.

Step by Step development for CREATE_DEEP_ENTITY operation

Thanks,

Syam