Deep Insert Implementation
The deep insert is the counterpart of $expand. A typical scenario is the creation of a parent style structure where entities are to be created that cannot be created independently. For example, in an SAP ERP system, you can usually create only a sales order with sales order items in it. Child elements are also sent using an HTTP post request. In SAP, this is a common and useful scenario because of many header-item relations and available BAPIs, such as BAPI_SALESORDER_CREATEFROMDAT2.
Deep Insert — HTTP POST to Entity Set
The request body is based on the result of a $expand statement.
In the SAP Gateway client, you can perform the $expand statement and use the Use as Request button to create the request body of a deep insert request.