Neo4j Relationship Index - Search on relationship property

南楼画角 提交于 2019-12-06 07:36:07

You can use legacy indexes or auto indexes to index relationships. Schema indexes do not support indexing relationships.

The reason for that: Typically you use use nodes to model the #things# or #entities# in your domain. Relationship wire up your world and put the nodes into a semantic context. When following that model you typically don't have to index relationships since your queries always start at a #thing# which is always a node.

In your model, you should rethink modelling, I guess it could make sense to have

 (account)-[:send]->(transaction)-[:to]->(account).

So transactions are a thing on its own and therefore become nodes.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!