如何在gremlin python中使用'as'关键字?

问题描述 投票:0回答:1

[尝试将我在Gremlin CLI中编写并测试的查询转换为gremlin-python时,我的unexpected token 'as'表达式遇到.as('foo')错误。使用gremlin-python时如何使用Gremlin as关键字?

graph-databases gremlin amazon-neptune gremlinpython
1个回答
1
投票

[当Gremlin步骤与Python保留字冲突时,该步骤将带有下划线后缀,因此对于as(),您应改为执行as_()。可以找到所有步骤的完整列表here,但目前它们是:

步骤-and_()as_()from_()is_()in_()not_()or_()with_()

令牌-Scope.global_

最新问题
© www.soinside.com 2019 - 2025. All rights reserved.