我必须找到从"今天开始的数据"和它的" displaystatus"必须为零。我正在使用它,但它也将返回具有displaystatus的文档。
$searchParams['index'] = 'events';
$searchParams['type'] = 'couchbaseDocument';
$searchParams['from'] = 0;
$searchParams['size'] = 1000;
$searchParams['body']['query']['filtered']['filter']['bool']['must'][]['range']['starttimestamp']['from'] = $today;
$searchParams['body']['query']['filtered']['filter']['bool']['must'][]['term']['displaystatus'] = 0;
$searchParams['body']['query']['filtered']['filter']['bool']['must'][]['terms']['cat_id'] = $interestIdArray;
答案 0 :(得分:1)
我不确定python是否像这样
{
"query": {
"filtered": {
"filter": {
"bool": {
"must": [
{
"range": {
"FIELD": {
"gte": ,
"lte":
}
}
},
{
"term": {
"FIELD": "VALUE"
}
},
{
"term": {
"FIELD": "VALUE"
}
}
]
}
}
}
}
}
应该在奇迹中工作。