0x90
0x90

Reputation: 41002

What should I do to setup a new Gremlin version for Neo4j?

I am using Neo4j - Graph Database Kernel 1.8

It uses this gremlin version:

gremlin> Gremlin.version()
==> 1.5

which is very old version.

I want to upgrade to gremlin 2.0 or 2.1 from the github project, since I can't run this command on gremlin 1.5:

gremlin> g.v(1).outE.has("weight", T.gte, 0.5f).weight
==> No such property: T for class: groovysh_evaluate

My question is what should I do, so I won't mess up all the entire environment of neo4j.

Upvotes: 1

Views: 244

Answers (2)

Peter Neubauer
Peter Neubauer

Reputation: 6331

the Gremlin plugin and the server will be upgraded in the next weeks, is that ok?

Upvotes: 1

Max De Marzi
Max De Marzi

Reputation: 1108

You can run:

import com.tinkerpop.gremlin.Tokens.T

To call the gremlin helper Tokens ("T") directly:

g.v(1).outE.has("weight", T.gte, 0.5f).weight

Or you can write:

g.v(0).outE.has("weight", Tokens.T.gte, 0.5f).weight

Write it in the gremlin shell.

Upvotes: 2

Related Questions