ASF GitHub Bot commented on TINKERPOP-1887:

Github user eonpatapon commented on the issue:

    After playing a bit, I'm not sure if what I want to do is supported by
    the gremlin-server. Actually I don't know how the bytecode should look.
    Given the following query in python GLV: 
        `g.V().has('foo', P.eq(('bar', 5)))`
    I translate it to the following bytecode:
        `[['V'], ['has', 'foo', ['eq', binding[bar=5]]]]`
    But this doesn't yield any results from the gremlin server.
    In tests I found some other form of query: `g.V().has('foo', ('bar', 
P.gt(5)))`, ie:
        `[['V'], ['has', 'foo', binding[bar=['eq', 5]]]]`
    But it doesn't yield any result either.
    Is there some bytecode reference somewhere to read more about it ? I
    didn't find any.

> Can't use bindings in predicates
> --------------------------------
>                 Key: TINKERPOP-1887
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-1887
>             Project: TinkerPop
>          Issue Type: Improvement
>          Components: python
>    Affects Versions: 3.3.1
>            Reporter: Jean-Philippe Braun
>            Priority: Major
> With the lastest version of gremlinpython it is not possible to define a 
> binding in a predicate:
> {code:java}
> g.V().has('foo', lt(('bar', 5))).toList(){code}

This message was sent by Atlassian JIRA

Reply via email to