Skip to Content
0

OData Filter Parameters to pass to Select Options

Feb 06, 2017 at 09:08 AM

691

avatar image
Former Member

Hi All,

I am trying to model service to standard component for a datetime field where I can pass the range which must consider the select options in ABAP.

I am passing the query like this: /sap/opu/odata/sap/ERP_UTILITIES_UMC/Accounts(AccountID='0100000342')/PaymentDocuments?$filter=(ExecutionDate gt (datetime'2016-10-01T00:00:00') or ExecutionDate lt (datetime'2016-12-01T00:00:00'))&$format=json

The above query doesnot pass the parameters as Option-High and Option-low as required.{Refer image below}

mcfu-selectoptions-nw.png

If I pass and as the for ExecutionDate then the filter is not being read.

Please guide how to work this out.

Thanks,

Srihari.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
Venugopal G Feb 07, 2017 at 12:02 PM
1

Hi Srihari,

Please check the below blog which explains for date ranges in detail

Date Ranges in Gateway

Regards,

Venu

Show 1 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Thank you Venu, this worked.

0
Krishna Kishor Kammaje
Feb 07, 2017 at 03:49 AM
1

This should work.

/sap/opu/odata/sap/ERP_UTILITIES_UMC/Accounts(AccountID='0100000342')/PaymentDocuments?$filter=ExecutionDate ge datetime'2016-10-01T00:00:00' and ExecutionDate le datetime'2016-11-01T00:00:00'

Show 1 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Thank you Krishna

0