In Neo4J, how to set the label as a parameter in a cypher query from Java?
问题 I have problems with parameter in cypher in Neo4J from Java. I run the the database embedded. The code should be like this (GraphDB.cypher goes directly to the ExecutionEngine) HashMap<String, Object> parameter = new HashMap<>(); parameter.put("theLabel1", "Group"); parameter.put("theRelation", "isMemberOf"); parameter.put("theLabel2", "Person"); GraphDB.cypher("MATCH (n1:{theLabel1})-[r:{theRelation}]->(n2:{theLabel2}) RETURN n1, r, n2", parameter); but it ends in this exception Exception in