Skip to Content
0

How to create an OData Query of SBO's Servicelayer filtered by UpdateTime and UpdateDate?

Mar 07 at 04:29 PM

16

avatar image

Hi,

I want to send a query to get all Items that have been change after a certain point in time, so that I will only update the ones that changed in my external system.

The items object has the properties UpdateDate and UpdateTime, e.g. "UpdateDate": "2018-03-07" and "UpdateTime": "09:05:59". How would I get all Items update after

2018-03-07 / 09:05:59?

I tried the following:

https://sboserver/b1s/v1/Items?$filter=UpdateDate ge datetime'2018-03-07' and UpdateTime ge datetime'14:00:00'

But this does not work and results in an error:

{
"error": {
"code": -1000,
"message": {
"lang": "en-us",
"value": "Query string error - the given value('datetime') of property 'UpdateTime' is of invalid time format"
}
}
}

It seems that last part of the query ("and UpdateTime ge datetime'14:00:00'") is causing the error.

What is way to achieve this?

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

0 Answers