Skip to Content
0
Feb 17, 2015 at 04:13 AM

How to use POST method in URL with $Expand

874 Views

Hi

I want to do the POST for Gateway Service URL. ( but it with $Expand addition)

The URL works correctly for GET method.

URL looks like this

http://XXX.XX:500/sap/opu/odata/sap/ZTEST_ORDER_SRV/ORDDetail(Userid='xyz',WorkType='36') ?$expand =ORDPerset,ORDHistorySet.

This works fine for GET method which gives multiple records for in Parts entity set (ORDPartset ), History Entity set (ORDHistoryset).

Work type is the key field for Parts entity set (ORDPartset ), History Entity set (ORDHistoryset) .

Requirement: If I use POST method and Pass worktype as '37', then it should be updated in these Parts entity set (ORDPartset ), History Entity set (ORDHistoryset) .

(Parts entity set (ORDPartset ), History Entity set (ORDHistoryset) is related to separate custom tables.

So finally entityset will update these custom tables)

So please let me know how to use the POST method in this case.

Thanks,

Shreedhar Gangadhar