如何为Neo4j设置新的Gremlin版本? [英] What should I do to setup a new Gremlin version for Neo4j?
本文介绍了如何为Neo4j设置新的Gremlin版本?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用Neo4j - Graph Database Kernel 1.8
它使用以下gremlin版本:
It uses this gremlin version:
gremlin> Gremlin.version()
==> 1.5
这是非常旧的版本.
我想从 github项目gremlin 2.0
或2.1
>,因为我无法在gremlin 1.5
上运行此命令:
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
我的问题是我应该怎么做,所以我不会弄乱neo4j
的整个环境.
My question is what should I do, so I won't mess up all the entire environment of neo4j
.
推荐答案
您可以运行:
import com.tinkerpop.gremlin.Tokens.T
要直接调用gremlin帮助程序令牌("T"):
To call the gremlin helper Tokens ("T") directly:
g.v(1).outE.has("weight", T.gte, 0.5f).weight
或者您可以写:
g.v(0).outE.has("weight", Tokens.T.gte, 0.5f).weight
在gremlin外壳中编写它.
Write it in the gremlin shell.
这篇关于如何为Neo4j设置新的Gremlin版本?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文