0% found this document useful (0 votes)
1 views4 pages

Odata

The document outlines various OData service endpoints for accessing and manipulating data related to batsmen and employees, including CRUD operations and query options such as filtering, ordering, and expanding. It provides specific URLs for retrieving, creating, updating, and deleting records, as well as examples of how to format requests for different data types. Additionally, it discusses media handling for various file types and includes examples of function imports and navigation paths within the OData services.

Uploaded by

pandu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views4 pages

Odata

The document outlines various OData service endpoints for accessing and manipulating data related to batsmen and employees, including CRUD operations and query options such as filtering, ordering, and expanding. It provides specific URLs for retrieving, creating, updating, and deleting records, as well as examples of how to format requests for different data types. Additionally, it discusses media handling for various file types and includes examples of function imports and navigation paths within the OData services.

Uploaded by

pandu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 4

/sap/opu/odata/SAP/ZKPR_BAT_SRV/BatsmenSet

/sap/opu/odata/SAP/ZKPR_BAT_SRV/BatsmenSet?$format=json
/sap/opu/odata/SAP/ZKPR_BAT_SRV/BatsmenSet(1)?$format=json

http://18.215.72.123:8080/sap/opu/odata/sap/ZKPR_BAT_SRV/BatsmenSet

Orderby
http://18.215.72.123:8080/sap/opu/odata/sap/ZKPR_BAT_SRV/BatsmenSet?$orderby=Inns
http://18.215.72.123:8080/sap/opu/odata/sap/ZKPR_BAT_SRV/BatsmenSet?$orderby=Inns
desc&$format=json
http://18.215.72.123:8080/sap/opu/odata/sap/ZKPR_BAT_SRV/BatsmenSet?$orderby=Inns
desc,Runs desc&$format=json

Filter
http://18.215.72.123:8080/sap/opu/odata/sap/ZKPR_BAT_SRV/BatsmenSet?
$filter=Avgerage gt '50'&$format=json
http://18.215.72.123:8080/sap/opu/odata/sap/ZKPR_BAT_SRV/BatsmenSet?
$filter=Highscore gt 200&$format=json

http://18.215.72.123:8080/sap/opu/odata/sap/ZKPR_BAT_SRV/BatsmenSet?
$filter=( Avgerage gt '50' or Strikerate gt '50' )&$format=json

http://18.215.72.123:8080/sap/opu/odata/sap/ZKPR_BAT_SRV/BatsmenSet?
$filter=( Avgerage gt '50' and Strikerate gt '50' )&$format=json

CRUD:- Create Read Update Delete


Read -
/sap/opu/odata/sap/ZEMPLOYEE_002_SRV/EmployeeSet + GET =>
employeeset_get_entityset.
/sap/opu/odata/sap/ZEMPLOYEE_002_SRV/EmployeeSet(2) + GET =>
EMPLOYEESET_GET_ENTITY
Create :-
/sap/opu/odata/sap/ZEMPLOYEE_002_SRV/EmployeeSet + POST + Payload =>
employeeset_create_entity
Update
/sap/opu/odata/sap/ZEMPLOYEE_002_SRV/EmployeeSet(6) + PUT + Payload =>
'EMPLOYEESET_UPDATE_ENTITY'
Delete
/sap/opu/odata/sap/ZEMPLOYEE_002_SRV/EmployeeSet(6) + DELETE =>
'EMPLOYEESET_DELETE_ENTITY'
***********************************************************************************
*************************

Access data through navigation


/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders('4969')/Items
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderItems =>
salesorderitems_get_entityset

Read with navigation path


/sap/opu/odata/sap/ZSALESORDER_001_SRV/SalesOrderHeaderS + Get
=>salesorderheader_get_entityset

/sap/opu/odata/sap/ZSALESORDER_001_SRV/SalesOrderHeaderS('4970')/OrderToItem_nav +
Get
=> salesorderitems_get_entityset
/sap/opu/odata/sap/ZSALESORDER_001_SRV/SalesOrderItemS =>
salesorderitems_get_entityset

***********************************************************************************
****************************
Expand Query option :-
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$expand=Items
salesorderheader_get_entityset => 100
salesorderitems_get_entityset => 7970 ....100 times

/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders('4970')?$expand=Items
salesorderheader_get_entity => 4970
salesorderitems_get_entityset => one time

If we have implemented this then we have to implement

/IWFND/TRACES
/IWFND/CACHE_CLEANUP

http://host:POrt/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?
$expand=Items&$format=json
***********************************************************************************
*****************************

They are automatically available in the framework, no further actions needed by


development.
$format
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$format=json
$expand
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$expand=Items
$select
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?
$select=SalesOrder,SalesOrg,Vtweg&$format=json
$count
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders/$count
$links
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders('4970')/$links/Items
ZC_SALESORDER_CDS/ZC_SalesOrder('180')/$links/to_items
$value
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders('4970')/Bstnk/
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders('4970')/Bstnk/$value
***********************************************************************************
***************

They are available, but they require implementation efforts from development.

Without implementation query option :-


$select :-
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?
$select=SalesOrder,Auart&$format=json

$count :-
/sap/opu/odata/sap/ZSALESORDER_001_SRV/SalesOrderHeaders/$count

$link :-
/sap/opu/odata/sap/ZSALESORDER_001_SRV/SalesOrderHeaders('764')/$links/Items

value :-
/sap/opu/odata/sap/ZSALESORDER_001_SRV/SalesOrderHeaders('764')/Auart?$format=json
$value
/sap/opu/odata/sap/ZSALESORDER_001_SRV/SalesOrderHeaders('764')/Auart/$value

$skiptoken
***********************************************************************************
**************

$batch :-

GET EmployeeSet?
$skip=0&
$top=20&
$select=EmployeeId%2cName%2cCity%2cCompanyName%2cDepartment%2cStratDate%2cEndDate
%2cSalary%2cCurrency&
$inlinecount=allpages

http://183.82.1.220:8073/sap/opu/odata/sap/ZEMPLOYEE_002_SRV

***********************************************************************************
**************************
$orderby
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$orderby=SalesOrder
desc&$format=json
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$orderby=Kunnr
asc,SalesOrder desc&$format=json

$filter
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$filter=Kunnr eq '1390'
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$filter=( Kunnr eq '1390'
or Kunnr eq '1175')
/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$filter=( Kunnr eq '1390'
or Kunnr eq '1175') and Vtweg eq '10'

List report page


/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$top

/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$skip

/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$inlinecount

/sap/opu/odata/sap/ZSALESORDER_002_SRV/SalesOrderHeaders?$skiptoken

***********************************************************************************

/sap/opu/odata/sap/ZSALESORDER_001_SRV/
Function Import:-
so_count_by_status

Importing :-
Customer
Exporting :-
Customer
NotProcesed
CompleteProcess
NotRelvent
*******************************************************************
Media Handling (Image, Audio, Video, PDF, ZIP, Excel Sheet, Text Files):-
1. Set Entity type as media in SEGW :- METADATA (hasStream)
2. Mime type property set as contetnt type in MPC_EXT
3. create_stream :- /sap/opu/odata/SAP/ZMEDIA_SRV/MediaSet + POST +
Payload + SLUG variable
4. get_stream :- /sap/opu/odata/SAP/ZMEDIA_SRV/MediaSet('ram3')/$value + GET
5. update_stream :- /sap/opu/odata/SAP/ZMEDIA_SRV/MediaSet('ram3')/$value + PUT +
Payload
6. delete_stream :- /sap/opu/odata/SAP/ZMEDIA_SRV/MediaSet('ram3')/$value + DELETE

Smartform pdf send to front end system

/sap/opu/odata/SAP/ZMEDIA_SRV/MediaSet('LH')/$value

You might also like