In my ML8 database there are some JSON documents containing Dtm fields. An example you can see below at 'Data:'. I have an element range index of scalar type dateTime on this field and to check if that works I use the query you see below at 'Test:'. The results are as expected.
Now when I try to query this, I want to grab all documents with a Dtm field past a certain date, this query returns nothing. You can see the query below at 'Query:'.
Data:
"Dtm": "2015-06-25T07:11:10.0Z"
Query:
var date = xs.dateTime("2015-06-01T14:38:09.145231+02:00");
var b = cts.elementRangeQuery("Dtm", ">", date);
var c = cts.search(b);
c
Test:
cts.elementValues([xs.QName("Dtm")], null, ['limit=3'], null, 1.0, null);
TestResult:
2015-06-11T17:43:36
2015-06-11T17:43:37
2015-06-11T17:43:38
Try using a
cts.jsonPropertyRangeQuery
, and usefn.subsequence
to grab just one page of results instead of all. For example like this:HTH!