0
我有一个例子像模式:SOLR:范围查询与和
id:1,date:2012-05-01,parent:p1
id:1,date:2012-05-01,parent:p2
id:1,date:2012-05-01,parent:p3
id:1,date:2012-05-02,parent:p1
id:1,date:2012-05-02,parent:p4
我想pefrorm上的“日期”范围查询并知道有多少新的/独特的父母每天都发生。换句话说,我想看看有多少新父母是通过时间增加的。对于给定的数据输出应该看起来像:
2012-04-31:0 (no parents existed an that time)
2012-05-01:3 (because three new parents occured at 2012-05-01: p1,p2,p3)
2012-05-02:4 (which is 3 parents from 2012-05-01 and 1 new unique parent p4 occured at 2012-05-02 which gives a total of 4)
2012-05-03:4 (no new parent was added this day...)
这种查询甚至可能在SOLR中吗?
这个查询只能算作在指定日期范围内的所有文件。我想统计在该范围内发生了多少个“父母”的新值。 – Pma
明白了 - 回答编辑! – Ansari
这是否适合你? – Ansari