知乎專欄 | 多維度架構 | | | 微信號 netkiller-ebook | | | QQ群:128659835 請註明“讀者” |
FilterBuilder filterBuilder = FilterBuilders.andFilter( FilterBuilders.existsFilter("title").filterName("exist"), FilterBuilders.termFilter("title", "elastic") ); SearchResponse response = client.prepareSearch("netkiller") .setPostFilter(filterBuilder) .get();