Hi,
I am a beginner and I am trying to use GDS to project my graph. I try to build a query like the tutorial https://neo4j.com/docs/graph-data-science/current/graph-project-cypher/#_multi_graph shows but failed. May I know why my code did not work?
My query is
CALL gds.graph.project.cypher(
'centrality',
'MATCH (n:AscdcProvidedCHO) RETURN id(n) AS id',
'MATCH (n:AscdcProvidedCHO)-\[r:subject|keywords{weight}\]->(m) WHERE NOT m.uri = "[http://dbpedia.org/resource/Insect](http://dbpedia.org/resource/Insect)" RETURN id(n) AS source, id(m) AS target, type(r) AS type'
)
The error message is:
Failed to invoke procedure `gds.graph.project.cypher`: Caused by: org.neo4j.exceptions.SyntaxException: Parameter maps cannot be used in MATCH patterns (use a literal map instead, eg. "{id: {param}.id}") (line 1, column 55 (offset: 54))
"EXPLAIN MATCH (n:AscdcProvidedCHO)-[r:subject|keywords{weight}]->(m) WHERE NOT m.uri = "About: Insect" RETURN id(n) AS source, id(m) AS target, type(r) AS type"
By the way, I am projecting the graph to use algorithms such as centrality and similarity algorithms. I am wondering if I can delete some nodes in the projected graph without changing the original database? The code from the tutorial seems only copy the original graph, but I want to project only part of it, and even make further changes after I get results of centrality and similarity. Can I do that with a projected graph?
Many thanks!