zoukankan      html  css  js  c++  java
  • Elasticsearch学习笔记之— excludes的高级用法

    GET /_search
    {
        "_source": {
            "includes": [ "obj1.*", "obj2.*" ],
            "excludes": [ "*.description" ]
        },
        "query" : {
            "term" : { "user" : "kimchy" }
        }
    }

    在Elasticsearch.Net里的使用方法如下:

    SearchRequest<object> request = new SearchRequest<object>("4d326769-d11e-46d5-8e3e-2160e17bafa0", "");
    request.Query = totalQuery;
    request.From = 0;
    request.Size = 100;
    request.Source = new SourceFilter
    {   Excludes
    = new Field("fname", null) }; var result = client.Search<object>(request); var documents = result.Documents;
  • 相关阅读:
    Mysql 数据库高级
    Mysql 数据库
    并发编程
    网络编程
    1113
    1112
    P相遇游戏
    中位数
    PETS
    打暴力程序的正确做法
  • 原文地址:https://www.cnblogs.com/wjx-blog/p/12167859.html
Copyright © 2011-2022 走看看