use of org.neo4j.ogm.session.request.FilteredQuery in project neo4j-ogm by neo4j.
the class NodeDeleteStatements method delete.
@Override
public CypherQuery delete(String label, Iterable<Filter> filters) {
FilteredQuery query = FilteredQueryBuilder.buildNodeQuery(label, filters);
query.setReturnClause(" OPTIONAL MATCH (n)-[r0]-() DELETE r0, n");
return new DefaultRowModelRequest(query.statement(), query.parameters());
}
use of org.neo4j.ogm.session.request.FilteredQuery in project neo4j-ogm by neo4j.
the class NodeDeleteStatements method deleteAndList.
@Override
public CypherQuery deleteAndList(String label, Iterable<Filter> filters) {
FilteredQuery query = FilteredQueryBuilder.buildNodeQuery(label, filters);
query.setReturnClause(" OPTIONAL MATCH (n)-[r0]-() DELETE r0, n RETURN ID(n)");
return new DefaultRowModelRequest(query.statement(), query.parameters());
}
use of org.neo4j.ogm.session.request.FilteredQuery in project neo4j-ogm by neo4j.
the class RelationshipDeleteStatements method deleteAndList.
@Override
public CypherQuery deleteAndList(String type, Iterable<Filter> filters) {
FilteredQuery query = FilteredQueryBuilder.buildRelationshipQuery(type, filters);
query.setReturnClause(" DELETE r0 RETURN ID(r0)");
return new DefaultRowModelRequest(query.statement(), query.parameters());
}
Aggregations