Professional Documents
Culture Documents
Hello everyone, in this tutorial we will learn what are the different query options available in
SAP Netweaver Gateway OData service.
Some of the above OData query options can be used directly and some required additional
implementation to be done from code perspective.Lets see what are they
http://www.saplearners.com/odataqueryoptionsinsapnetweavergateway/ 1/3
4/23/2017 ODataQueryOptionsinSAPNetweaverGatewaySAPFiori,SAPHANA,SAPUI5,SAPNetweaverGatewayTutorials,InterviewQuestions|SAPLearners
You can directly add these query options directly to the service and the service will respond
accordingly.
$select
Syntax : http://<server>:<port>/sap/opu/odata/sap/<service_name>/ProductsSet?
$select=ProductId,Name,Description
$count
Syntax : http://<server>:<port>/sap/opu/odata/sap/<service_name>/ProductsSet??$count
$expand
Syntax : http://<server>:<port>/sap/opu/odata/sap/<service_name>/Suppliers?
$expand=Products
$format
Syntax : http://<server>:<port>/sap/opu/odata/sap/<service_name>/ProductsSet?
$format=json
Read $links
Syntax : http://<server>:
<port>/sap/opu/odata/sap/<service_name>/Products(1001)/$links/Category
$value
Syntax : http://<server>:
<port>/sap/opu/odata/sap/<service_name>/Products(1000)/Name/$value
http://www.saplearners.com/odataqueryoptionsinsapnetweavergateway/ 2/3
4/23/2017 ODataQueryOptionsinSAPNetweaverGatewaySAPFiori,SAPHANA,SAPUI5,SAPNetweaverGatewayTutorials,InterviewQuestions|SAPLearners
$orderby
$top
$skip
$lter
$inlinecount
$skiptoken
In our next tutorial we will dig deep into these OData query options one by one. Stay tuned to
us for more SAP Netweaver Gateway tutorials.
Thank you. Please feel free to comment and let us know your feedback.
Prakash
http://www.saplearners.com/odataqueryoptionsinsapnetweavergateway/ 3/3