Mentor SAP

Search Help Operation Mapping

Service implementation via mapping supports only read access (READ and QUERY). CUD methods have to be implemented via code or mapping to appropriate RFC function modules.

 

 

Service Implementation via Mapping Development Flow

To start the service implementation, create an entity type and entity set based on the import of a search help. To perform service implementation, use mapping of the read and query method of the search help.

 

 

Defining the Data Model and Service Implementation

The wizard for creating an entity type based on a search help performs two steps: data model definition and service implementation. In the first screen, you select the appropriate search help and select a (readable) name for the entity type (here: Country).

 

Select the Create Default Entity Set checkbox so that an entity set with the name <EntityName>Set (here: CountrySet) is generated.

 

Also select the Query and Read checkboxes so that the read and query method implementations are mapped automatically.

 

 

Defining the Data Model and Service Implementation — Wizard

In the second screen, you select the fields that should be part of the entity type and entity set. In the third step, you specify the key field(s).

 

 

Service Implementation Result

The wizard has performed the mapping for input and output. For the query method, the range tables have been mapped so that $filter is supported. For the read method, an input parameter has been mapped for the property that has been marked as a key field.

 

 

Search Help Generator — $filter Support

As a result of the service implementation, there is out-of-the-box support for $filter, as shown in the figure Search Help Generator — $filter Support, where $filter is used in the Gateway client using the following URI:

 

/sap/opu/odata/SAP/ZGW100_XX_SEARCHHELP_SRV/CountrySet?$filter=Key eq 'US'&$format=json