cancel
Showing results for 
Search instead for 
Did you mean: 

Gateway Service Create with Multiple Line Items

Former Member
0 Kudos

Hello,

I observed that you can create an entity in gateway with only a Flat structure, no nested structure or a structure with an internal table is not supported. As i have a requirement of creating a purchase order with multiple items through a create call in gateway service.how do i achieve this.Can any one provide me some direction.

regards

Kaushik

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hello Krishna,

thank you for your response,if there is a similar request for update,how do i implement it.

regards

Kaushik

kammaje_cis
Active Contributor
0 Kudos

For update of several entities, you need to use $batch.

kammaje_cis
Active Contributor
0 Kudos

Kaushik,

In your case Purchase Order header will be an Entity and Purchase Order Line item another entity. You define relationship between them using Associations and Referential Constraints.

For fetching both at a time, you need to use a '$expand'. For creating both at a time, you use 'Deep Insert'.

I would suggest you to go through odata.org and search these concepts.

Also you can read more here.

Similar Discussion.

About deep Insert

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/e0d92637-3d0d-2f10-ebb2-efc1f40a8...

About $expand

Basic and Generic Expand - SAP NetWeaver Gateway - SAP Library