Elasticsearch / Kibana查询

时间:2016-11-22 12:44:12

标签: elasticsearch kibana

如何在Kibana / ES中搜索百分比。我有%7e的网址,我想查询这些。但是,它始终显示"未找到结果"。有什么想法吗?

1 个答案:

答案 0 :(得分:0)

您是否使用not_analyzed字段进行了尝试?

尝试这样的映射:

{
  "template": "*",
  "settings": {
    "number_of_shards": 1,
    "number_of_replicas": 0
  },
  "mappings": {
    "_default_": {
      "dynamic_templates": [{
        "string_fields": {
          "match": "*",
          "match_mapping_type": "string",
          "mapping": {
            "type": "string",
            "fields": {
              "raw": {
                "type": "string",
                "index": "not_analyzed"
              }
            }
          }
        }
      }]
    }
  }
}

然后,您可以查询名称为[fieldname].raw的字段。也许这有帮助。