0
votes

What is wrong with this query

 var result = Neo4jController.m_graphClient.Cypher
                .Match("(A:" + objWorld.getLabel() + " { Name : {Name} })")
                .Create("(A)-[R:" + Rel_World.world_country + "]->(B:" + objcountry.getLabel() + "{ objcountry }")
                .WithParams(new
                {
                    Name = objWorld.Name,
                    objcountry = objcountry
                })
                .Return((B, R) => new
                {
                    CountryCount = B.Count(),
                    RelationCount = R.Count()
                })
                .Results
                .Single();

I am getting this error Message=SyntaxException: Invalid input 'R': expected whitespace, comment or ')' (line 3, column 1) "RETURN count(B) AS CountryCount, count(R) AS RelationCount"

I am using Neo4jclient to interact with neo4j

1
Got it. Forgot to add a ')' in the create query. Sorry - Nipun
You should post that as the answer to your own question, so that you can mark the question as closed. - Tatham Oddie

1 Answers

0
votes

Forgot to add a ')' in the query field.