使用 dmesg 来查看一些硬件或驱动程序的信息或问题。

es 通配符匹配查询

Elasticsearch | 作者 hansongnan | 发布于2017年09月04日 | 阅读数:10915

 "location" 字段创建的时候设置了不分词

"properties" : { "location" : { "type" : "string", "index" : "not_analyzed" } }
现在有一条这样的数据
  "location": "e:\\内勤工作\\其他\\gr、nd\\xitong\\documents and settings\\jjkk\\my documents\\my documents.exe"
使用通配符查询
{"wildcard": {
                  "location": {
                     "value": "*my documents.exe*"
                  }
               }} 可以查询到内容,但是当查询里面有“\\”
"wildcard": {
                  "location": {
                     "value": "*xitong\\documents and settings\\jjk*"
                  }
               }}查询的时候就查不到内容,为什么会出现这种情况
 
已邀请:

Cheetah

赞同来自: hansongnan laoyang360 learnonly

\\正则匹配时需要转义,换成\\\\

要回复问题请先登录注册