Solr 多重搜索和按日期范围分组
如果有问题在具有相同短语但不同时间范围的查询中执行多个 Solr 查询。 示例:
search for "atom" at:
2011-04-01T10:20:22.0Z TO 2011-04-01T12:20:22.0Z
2011-03-08T10:20:22.0Z TO 2011-03-08T12:20:22.0Z
2011-02-05T10:20:22.0Z TO 2011-02-05T12:20:22.0Z
所以我需要每 2 小时间隔发送几条消息。 首先,我想到了分面搜索,但我不认为这是一种方法,不是吗?
第二个想法是为每个时间范围触发一个 solr 请求。但可能需要太多(网络)开销,因为这个示例只是一个简化版本。
也许有人有想法,我该如何处理这个问题?哪种 solr 功能是实现此目的的最佳方法?
谢谢。
if have the problem to execute multiple Solr queries at ones with the same phrase but for different timeranges.
Example:
search for "atom" at:
2011-04-01T10:20:22.0Z TO 2011-04-01T12:20:22.0Z
2011-03-08T10:20:22.0Z TO 2011-03-08T12:20:22.0Z
2011-02-05T10:20:22.0Z TO 2011-02-05T12:20:22.0Z
So i need a few messages from each 2 hour interval.
First of all, i thought about facet search, but i don't think, thats a way, is'n it?
2nd idea was to fire one solr request for every time range. But probably there is to much (network)overhead for that, because this example is only an simplified version.
Maybe anybody has an idea, how could i handle this? What solr functionality is the best way for this?
Thank you.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
将 FieldCollapsing 与 group by query 选项结合使用。
Use FieldCollapsing with the group by query option.