Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
07-21-2020 05:58 PM
I am trying to run the following code.
CALL gds.graph.create.cypher(
'my-cypher-graph',
'MATCH (n:Person) RETURN id(n) AS id',
'MATCH (a:Person)-[:LIKES]->(b:Person) RETURN id(a) AS source, id(b) AS target'
)
YIELD graphName, nodeCount, relationshipCount, createMillis;
But I got this error: Neo.ClientError.Procedure.ProcedureCallFailed
Failed to invoke procedure gds.graph.create.cypher
: Caused by: java.lang.IllegalArgumentException: Node-Query returned no nodes
Can you please help?
Solved! Go to Solution.
07-22-2020 02:01 PM
It's in the error message: your first query doesn't contain any nodes. Try running MATCH (n:Person) RETURN COUNT(n)
to double check your cypher.
07-22-2020 02:01 PM
It's in the error message: your first query doesn't contain any nodes. Try running MATCH (n:Person) RETURN COUNT(n)
to double check your cypher.
07-22-2020 03:46 PM
Thanks Alicia. You are right. This was happening because the db had 0 nodes. The gds.graph.create.cypher function actually does not CREATE the nodes.
All the sessions of the conference are now available online