Match all
The most simple query, which matches all documents, giving them all a _score
of 1.0
.
最简单的查询,它匹配所有文档,使它们全部_score
为1.0
。
GET /_search
{
"query": {
"match_all": {}
}
}
Copy as cURLView in Console
The _score
can be changed with the boost
parameter:
该_score
可以用boost
参数改变:
GET /_search
{
"query": {
"match_all": { "boost" : 1.2 }
}
}
Copy as cURLView in Console
Match None Query
This is the inverse of the match_all
query, which matches no documents.
这是match_all
查询的反函数,不匹配任何文档。
GET /_search
{
"query": {
"match_none": {}
}
}
Copy as cURLView in Console