solr索引嵌套文档 [英] solr index nested document

查看:395
本文介绍了solr索引嵌套文档的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

solr是否支持嵌套文档?是否有更好的方法来实现此类文档?

Does solr support nested documents? And is there a better way to achieve this sort of document?

<doc>
    <field name="name">Mr. Test</field>
    <field name="case">
        <field name="link">http://foo.com</field>
        <field name="date">1-2-1234</filed>
        <field name="title">My title</filed>
    </field>
    <field name="case">
        <field name="link">http://foo.com/2/</field>
        <field name="date">1-2-1234</filed>
        <field name="title">My title 2</filed>
    </field>
</doc>

我所拥有的是多个案件的一部分。这种形式的模式是否与solr合法?不同的人也可以是同一案件的一部分。所以它看起来像关系数据库的任务,但我在这个项目中使用solr。

What I have is a person that has been part of multiple cases. Is this form of schema legal with solr? A different person can also be part of the same case. So it does look like a task for a relational database, but I'm using solr for this project.

推荐答案

不,Solr不支持嵌套结构。另请参阅这个其他问题

No, Solr doesn't support that nested structure. Have a look at this other question too.

这篇关于solr索引嵌套文档的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆