将参数传递给Cypher查询node_auto_index

时间:2015-03-09 13:15:18

标签: neo4j cypher spring-data

我正试图将参数传递给Cypher查询node_auto_index而没有任何运气。

DecisionRepository.class:

@Query("START d=node:node_auto_index(':text') MATCH (d:Decision) RETURN d") 
List<Decision> searchDecisions(String text);

用法:

List<Decision> searchDecisions = decisionRepository.searchDecisions("name:aDbma~ OR name:mosyl~");

是否可能,如果可能,我错了?

1 个答案:

答案 0 :(得分:2)

使用query parameters

START d=node:node_auto_index({myLuceneQuery}) RETURN d;

然后将"name:aDbma~ OR name:mosyl~"作为{myLuceneQuery}

发送