我可以调用 2 个 apoc 程序并用 cypher 组合结果集吗?
Can I call 2 apoc procedures and combine the result sets in cypher?
我想调用 2 个不同的过程并合并输出以在一个密码查询中进一步匹配。可能吗?
所以,为了更清楚一点:
* 我已经创建了一个手动索引,我在 call apoc.index.search("myindex","searchterm")
的查询中使用了它
* 我也有一些自己的程序,我想与上面的 apoc.index.search 一起使用。
所以我会这样
call
apoc.index.search("myindex","searchterm") and my.own.procedure("searchterm")
yield both resultsets
有没有办法做到这一点?
感谢@cybersam 的评论。我发现了如何使用两个过程调用。在我的例子中是:
```
CALL my.own.procedure(params) YIELD node as molecule, score as score
CALL apoc.index.search('search-index',{keyword}) YIELD node as finding
MATCH (molecule)<-[:CONTAINS]-(d:Document)
MATCH (finding)--(d)
RETURN d
```
我想调用 2 个不同的过程并合并输出以在一个密码查询中进一步匹配。可能吗?
所以,为了更清楚一点:
* 我已经创建了一个手动索引,我在 call apoc.index.search("myindex","searchterm")
的查询中使用了它
* 我也有一些自己的程序,我想与上面的 apoc.index.search 一起使用。
所以我会这样
call
apoc.index.search("myindex","searchterm") and my.own.procedure("searchterm")
yield both resultsets
有没有办法做到这一点?
感谢@cybersam 的评论。我发现了如何使用两个过程调用。在我的例子中是:
```
CALL my.own.procedure(params) YIELD node as molecule, score as score
CALL apoc.index.search('search-index',{keyword}) YIELD node as finding
MATCH (molecule)<-[:CONTAINS]-(d:Document)
MATCH (finding)--(d)
RETURN d
```