[ 
https://issues.apache.org/jira/browse/TINKERPOP-1549?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15812055#comment-15812055
 ] 

Daniel Kuppitz commented on TINKERPOP-1549:
-------------------------------------------

Negative values can be used for "skip X and take the remainder". This can't be 
done using `tail()`, since you would have to know the number of elements 
upfront.

{noformat}
gremlin> g.V().tail(3)
==>v[4]
==>v[5]
==>v[6]
gremlin> g.V().range(3, -1)
==>v[4]
==>v[5]
==>v[6]
gremlin> g.addV()
==>v[12]
gremlin> g.V().tail(3)
==>v[5]
==>v[6]
==>v[12]
gremlin> g.V().range(3, -1)
==>v[4]
==>v[5]
==>v[6]
==>v[12]
{noformat}

> Add more RangeStep test cases
> -----------------------------
>
>                 Key: TINKERPOP-1549
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-1549
>             Project: TinkerPop
>          Issue Type: Improvement
>          Components: process
>            Reporter: Daniel Kuppitz
>
> We do support negative values in {{RangeStep}}, e.g. to have an open end 
> ({{skip()}} semantics). This is broken in DSEG, probably because we don't 
> cover this case in our test suite (not verified).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to