# 根据条件查询某个字段是否存在或为空的情况   
GET colordata_bbs_series/baseinfo/_search
{
  "size": 1000,
  "query": {
    "bool": {
      "must_not": [
        {
          "regexp": {
            "SearchBrand": {
              "value": ".{0,}"
            }
          }
        },{
          "exists": {
            "field": "NumberofReplys"
          }
        }
      ],
      "must": [
        {
          "term": {
            "ClientID": {
              "value": "M103801"
            }
          }
        },
        {
          "term": {
            "realChannel": {
              "value": "weixin"
            }
          }
        },
        {
          "range": {
            "CreateTime": {
              "gte": "2021-10-26 00:00:00",
              "format": "yyyy-MM-dd HH:mm:ss"
            }
          }
        },
        {
          "term": {
            "thread": {
              "value": "0"
            }
          }
        }
        
      ]
    }
  }
}

 

相关文章:

  • 2021-12-10
  • 2022-01-03
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-08-04
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-10-30
  • 2022-12-23
  • 2021-11-05
  • 2022-12-23
  • 2022-12-23
  • 2021-05-26
  • 2022-12-23
相关资源
相似解决方案