组合过滤器 | Elasticsearch: 权威指南 | Elastic https://www.elastic.co/guide/cn/elasticsearch/guide/current/combining-filters.html

这种情况下,我们需要 bool (布尔)过滤器。 这是个 复合过滤器(compound filter) ,它可以接受多个其他过滤器作为参数,并将这些过滤器结合成各式各样的布尔(逻辑)组合。

布尔过滤器

一个 bool 过滤器由三部分组成:

{
"bool" : {
"must" : [],
"should" : [],
"must_not" : [],
}
}
must
所有的语句都 必须(must) 匹配,与 AND 等价。
must_not
所有的语句都 不能(must not) 匹配,与 NOT 等价。
should
至少有一个语句要匹配,与 OR 等价。

游标查询 Scroll | Elasticsearch: 权威指南 | Elastic https://www.elastic.co/guide/cn/elasticsearch/guide/current/scroll.html

[root@hadoop3 xiaole_chk_url]# curl hadoop3:9200/direct_vote/kwaddress/_search?pretty=true -d "{"_source":false,"from":204500,"size":100}"
{
"error" : {
"root_cause" : [ {
"type" : "query_phase_execution_exception",
"reason" : "Result window is too large, from + size must be less than or equal to: [10000] but was [204600]. See the scroll api for a more efficient way to request large data sets. This limit can be set by changing the [index.max_result_window] index level parameter."
} ],
"type" : "search_phase_execution_exception",
"reason" : "all shards failed",
"phase" : "query",
"grouped" : true,
"failed_shards" : [ {
"shard" : 0,
"index" : "direct_vote",
"node" : "fIuqvDKQTgW2xLMofruOkA",
"reason" : {
"type" : "query_phase_execution_exception",
"reason" : "Result window is too large, from + size must be less than or equal to: [10000] but was [204600]. See the scroll api for a more efficient way to request large data sets. This limit can be set by changing the [index.max_result_window] index level parameter."
}
} ]
},
"status" : 500
}
[root@hadoop3 xiaole_chk_url]#

  

最新文章

  1. 获取iOS设备型号iphone ipad
  2. MyBatis中的resultType和resultMap
  3. 对数据库触发器new和old的理解
  4. response下载文件 (转载)
  5. C# 与C/C++相互调用
  6. 【英语】Bingo口语笔记(42) - Got系列
  7. 编译linux内核以及depmod的使用
  8. EasyUI兼容IE问题
  9. 利用switch语句计算特定的年份的月份共有几天。
  10. Cookie的基本使用
  11. QQ群开放接口
  12. Linux 宿主机安装 MiniGUI
  13. 网络协议之ipv6
  14. Android学习开发中如何保持API的兼容
  15. Shiro限制登录尝试次数
  16. ecplise中设置字符编码
  17. 【POI】java对excel的读写操作
  18. c/c++拷贝构造函数和关键字explicit
  19. Add Languages to Your Xamarin Apps with Multilingual App Toolkit
  20. Windows下nginx+tomcat实现简单的负载均衡

热门文章

  1. 预测学习、深度生成式模型、DcGAN、应用案例、相关paper
  2. tcpdump命令使用方法
  3. csr_matrix参数解析
  4. 编译器:gcc, clang, llvm
  5. Stuts2学习——HelloWorld
  6. idea必选配置
  7. Hadoop Mapreduce 中的Partitioner
  8. Vmware下的Linux系统,安装WPS报错:[Errno 256] No more mirrors to try
  9. buf.readUInt16BE()
  10. Python 实现批量查询IP并解析为归属地