Maven dependency version Neo4j - Cypher - query syntax

74 views
Skip to first unread message

Samwillie

unread,
May 10, 2012, 1:11:18 PM5/10/12
to Neo4j
Hi experts,

I am using the maven dependency Neo4j version 1.8.M01 which also pulls
in the cypher 1.8.M01.

When trying to delete a node using cypher query, I get the error ->
"return clause expected" error.

start n = node(2) match n-[r]->() delete r, n

The following post provides an answer - to use 1.8-SNAPSHOT, but this
is not in the maven repository.

http://groups.google.com/group/neo4j/browse_thread/thread/a4cd06df992ea84b?fwc=1

The query does not work in my console too. But it works in
http://console.neo4j.org.

Any directions would be helpful..

Thanks

Michael Hunger

unread,
May 10, 2012, 1:16:03 PM5/10/12
to ne...@googlegroups.com
1.8-SNAPSHOT is available as download from neo4j.org

or from http://m2.neo4j.org/snapshots (not maven central)

but 1.8.M02 is also due very soon.

Michael

Andres Taylor

unread,
May 10, 2012, 2:59:52 PM5/10/12
to ne...@googlegroups.com
On Thu, May 10, 2012 at 7:11 PM, Samwillie <pnk...@gmail.com> wrote:
Hi experts,

I am using the maven dependency Neo4j version 1.8.M01 which also pulls
in the cypher 1.8.M01.

<snip>
 
The query does not work in my console too. 

Hmm... How come you have a console if you are using maven dependencies? Is it possible you have installed an older version of the server?

Andrés 

Samwillie

unread,
May 11, 2012, 6:02:06 AM5/11/12
to Neo4j
Hi Michael and Andres,

Thanks for your replies. I will wait for 1.8.M02 then.

Meanwhile, I have managed to iterate through the relationships and
remove them and then do a Node.delete().

Andres, yes the server I have installed is 1.7 version - ah so this is
why I don't see the result. But the web application that accesses the
server using RestGraphDatabse uses 1.8.M01.

Thanks again..

On May 10, 8:59 pm, Andres Taylor <andres.tay...@neotechnology.com>
wrote:

Andres Taylor

unread,
May 11, 2012, 9:25:31 AM5/11/12
to ne...@googlegroups.com
On Fri, May 11, 2012 at 12:02 PM, Samwillie <pnk...@gmail.com> wrote:
Hi Michael and Andres,

Thanks for your replies. I will wait for 1.8.M02 then.

You are welcome to wait. Your query works in 1.8.M01 though - I believe your setup is the problem you're facing.
 
Andres, yes the server I have installed is 1.7 version - ah so this is
why I don't see the result. But the web application that accesses the
server using RestGraphDatabse uses 1.8.M01.

You need to use the same version in your server and your client. Things might work, and they might not. I believe this is the problem you need to fix.

HTH,

Andrés
Reply all
Reply to author
Forward
0 new messages