Tag: cypher spring data neo4j

来自JPA的@Formula注解类似于Spring数据neo4j?

我想使用neo4j在数据库级别计算我的域对象的一些属性,并返回只读结果。 在JPA中,可以通过域对象实体字段上的@Formula注解来实现: @Formula("(select avg(f.rating) from Feedback f where f.offer_id = offer_id)") private Double rating; 在Spring数据neo4j中应该如何实现相同的行为呢? 我写了一个Cypher查询,但不知道在哪里使用它。