沙师弟,师父的充电器掉了

如果构建索引查询更快

Elasticsearch | 作者 smtl_20113 | 发布于2017年01月13日 | 阅读数:5277

数据格式:
{
  "date": 1484219926,
  "uid": "1234567",
  "interest": [
    "2000001",
    "2000002",
    ".... 200050"
  ],
  "other": "xxxx"
}
想得到一定时间内某个interest的总个数,如下sql
select count(*) from xxxxx where date>time1 and date<time2 and interest="20000xxx"
如何构建索引或者如何存放interest,能让这个查询更快, interest的长度dag大概500多个
已邀请:

wangx

赞同来自:

你好 请问你做出来了吗

要回复问题请先登录注册