Skip to Content

How to search using time field in the odata service?

i am using filter query option in the odata service

/sap/opu/odata/ztest/MeasurementsSet?$filter=Mtime eq time'20:32:32'

or /sap/opu/odata/ztest/MeasurementsSet?$filter=Mtime eq '20:32:32'

MTIME --type is edm.time .

<Property Name="Mtime" Type="Edm.Time" Nullable="false" Precision="0" sap:label="MeasurementTime" sap:creatable="false" sap:updatable="false" sap:sortable="false"/>

i am giving values mtime property to fetch the records in the entityset.

sap gateway is not accepting the above two URI format?

it's telling bad request or Invalid parametertype used at function..

which format i can use to fetch the records using TIME fields in the ENTITYSET Method?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    avatar image
    Former Member
    Jun 21, 2017 at 10:37 AM

    Hello Venkat,

    Please send time as below and check -

    /sap/opu/odata/ztest/MeasurementsSet?$filter=Mtime eq time'PT20H32M32S'

    Regards,

    Add comment
    10|10000 characters needed characters exceeded