使用gremlin控制台远程连接到Neptune DB实例,我用一个特定的标签获取所有的边缘,并希望根据输出顶点的id对它们进行排序。我得到了一个错误:"code":"UnsupportedOperationException","detailedMessage":"com.amazon.neptune.storage.volcano.ast.CutoffNode cannot be cast to com.amazon.neptune.storage.volcano.ast.AbstractGroupNode"。
样本数据:
g.addV('user').property(id,'1').
addV('content').property(id,'2').
addE('history').property('val',9).from(g.V('1')).to(g.V('2'))查询和产出:
g.E().hasLabel('history').order().by('val')
==>e[3][1-history>2]g.E().hasLabel('history').outV().id()
==>1g.E().hasLabel('history').order().by(outV().id())
{"requestId":<stuff>,"code":"UnsupportedOperationException","detailedMessage":
"com.amazon.neptune.storage.volcano.ast.CutoffNode cannot be cast to
com.amazon.neptune.storage.volcano.ast.AbstractGroupNode"}我希望最后一次的结果和第一次一样。我在TinkerGraph中尝试过同样的遍历,但是没有得到一个错误,所以从这个和消息来看,这是海王星的问题。谷歌什么都没提过。
是否有一条能实现我想要的东西的穿越?我做错了什么?
发布于 2019-11-19 02:55:00
我将研究为什么会抛出错误,但在短期内,我认为这个解决办法应该有效。如果没有,请告诉我。
g.E().order().by(identity().outV().id())
干杯,开尔文
https://stackoverflow.com/questions/58720484
复制相似问题