SAP has provided with GW SP04 a basic integration framework for creating an OData service based on the Generic Interaction Layer (GenIL). This offers a simple and quick way of exposing the business data in the form of OData services. You can create your own service based on Genil comonent in couple of minutes.
Make sure that the following system prerequisites are fulfilled:
- You have an SAP NetWeaver Gateway Hub system where software component IW_FND 250 is deployed.
- You should have the following software components deployed either on the SAP NetWeaver Gateway Hub system or on the SAP backend system:
- IW_BEP 200
- IW_GIL 100
- WEBCUIF 7.0 SP03 and above
Only on the Root node the CRUD operations are supported on Access Object and Dependent Object. The query on a dependent object can only be triggered via a navigation property of a root/access object.
Filtering is supported only for those properties of an entity (corresponding to the root/access object) which has a similar named field in the attribute structure of the default query. . Important This means if an attribute is in the Query structure as well as Attribute structure then only you can call the Query other wise you need to create your own query with such parameters in the Genil componet.
I tried creating one such service referring to the help document at
The documentation is self sufficient to create such a service.
I will create a simple service on BP Genil Component which will fetch the data in the service
1. Logon to the backend system where IW_GIL 100, IW_BEP 200 and WEBCUIF 7.0 SP03 is installed. (normally this would be your CRM system where you have the Genil components)
2. Goto transaction SEGW -> Choose Environment and SAP NetWeaver Gateway Srvc. Generator for GenIL.
Enter the details as below.
Genil component (here BP) , Model and Data provide class name (will be generated by the system) , package (and transport request if package is not $tmp)
Check Configure GW model and service and enter service and model information
3.Choose Execute , Log window would appear check everything is green.
4. Now Change the default Query in the Model Provider class method /IWGIL/IF_GENIL_MODEL_INFO~GET_DEFAULT_QUERY to BuilHeaderSearch (as this query can be executed without parameters, And in BP Component the Query attributes and Result attributes differ)
5.Now add and activate the service in the gateway system using transaction /n/iwfnd/maint_service.
6. Once Activated Test using the ‘Explore Service’ Button.
Here you go…You will get the results.
P.S. If no GUID/$filter parameters are passed it will do a selectall query.