Jovo Krneta
Jovo Krneta

Reputation: 558

Cypher with clause unknown identifier `n` error.

This is my cypher query:

start n=node(*) match p=n-[r:OWES*1..200]->n   
with count(n) as numbern ,count(r) as numberr 
where  HAS(n.taxnumber) and  numbern >= numberr 
return extract(s in `relationships(p) : s.amount), extract(t in nodes(p) : ID(t)), length(p); `

This gives me Unknown identifier n error. What is wrong with this? I use Neo4j 1.8.2 for this.

Upvotes: 0

Views: 153

Answers (1)

Michael Hunger
Michael Hunger

Reputation: 41676

n is no longer visible after your WITH, p is also not visible then.

This query doesn't make any sense, what do you want to achieve with the aggregation?

Both counts return the same number btw.

Besides what we already discussed in the other issues, what do you want to achieve?

Upvotes: 1

Related Questions