cancel
Showing results for 
Search instead for 
Did you mean: 

IoT built-in OData API datetime filter not working

Former Member
0 Kudos

I am using the builtin OData API from the IoT MMS services and datetime filtering is not working.

I tried this request :

https://<host>/com.sap.iotservices.mms/v1/api/http/app.svc/MY_TABLE?$filter=MY_COLUMN gt datetime'2016-01-01T00:00:00'


and I get the following error: Requested entity could not be found



<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">

<code></code>

<message xml:lang="en-US">Requested entity could not be found.</message>

</error>

I know that the column and table exist, and that the column is of type datetime.I can also filter by any other column (of other types, like string) and it works, so the filter syntax should be good.

Is the filtering of datetime not supported by the builtin OData API ?

Accepted Solutions (1)

Accepted Solutions (1)

anton_levin
Advisor
Advisor
0 Kudos

Hi Rares,

a filter syntax is actually correct. I am going to check what the problem is on the MMS side and will keep you updated.

Sorry for the inconvenience,

Anton

anton_levin
Advisor
Advisor
0 Kudos

Update.

A fix will be a part of the upcoming MMS release which should be rolled out together with the HCP Trial update next week.

Many thanks for reporting that,

Anton

Former Member
0 Kudos

Thanks, will wait for the update.

Answers (1)

Answers (1)

former_member186822
Participant
0 Kudos

Is the MMS release rolled out ?

I have the same problem with filtering, as described here.

anton_levin
Advisor
Advisor
0 Kudos

Hello Rolf,

yes. Current MMS version is 2.25.0. What version are you working with? Maybe you may share more details on your issue? (how does your query string looks like etc)

Regards,

Anton

former_member186822
Participant
0 Kudos

http://help.sap.com/saphelp_hanaplatform/helpdata/en/25/6287e2132b478b9066017a4a4998e4/content.htm

Thank you for a quick answer !

It's working now.

I tried the Filter Option for "Starts with", and that's not working.

I found the url where supported options are defined, and "starts with" is not part of that.

Supported options are working perfect. 🙂