我在 QBE 中寻找日期范围查询。我正在尝试以下查询示例
https://Server:port/v1/qbe?format=json&pageLength=10&start=1&directory=/json/&options=search_option_advanced_date&query={"$query":{
"$and":[{"creation_date":{"$le":"2018-12-12T05:40:47.496"}},{"creation_date":{"$ge":"2017-12-12T05:40:47.496"}}],"$filtered":true}}
在这里,我在“/Creation_Date_date”上创建了路径范围索引和“Creation_Date_date”上的元素范围索引也在持久选项的 search_option_advanced_date 文件的约束下添加
<constraint name="creation_date">
<range type="xs:date">
<element name="Creation_Date_date"/>
</range>
</constraint>
虽然结果应该被获取,但我得到了以下空白
{
"snippet-format":"snippet",
"total":0,
"start":1,
"page-length": 10,
"selected": "include-with-ancestors",
"results":[],
"facets": {
"EntityType":{"type":"xs:string", "facetValues":[]},
"Category":{"type":"xs:string", "facetValues":[]},
"Genre":{"type":"xs:string", "facetValues":[]},
"creation_date":{"type":"xs:date", "facetValues":[]}
},
"metrics": {
"query-resolution-time":"PT0.016599S",
"facet-resolution-time":"PT0.000578S",
"extract-resolution-time":null, "total-time":"PT0.017743S"
}
}