[
https://issues.apache.org/jira/browse/TINKERPOP-2100?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16699049#comment-16699049
]
stephen mallette edited comment on TINKERPOP-2100 at 11/26/18 2:47 PM:
-----------------------------------------------------------------------
Here's a workaround - i added an edge to the "modern" graph that had "software"
with no "name" property:
{code}
gremlin> g.V().
......1> hasLabel("person").
......2> out("created").
......3> order().by(coalesce(values('name'),constant('x'))).
......4> choose(has("name"),values('name'),constant('x')).
......5> fold()
==>[lop,lop,lop,ripple,x]
{code}
was (Author: spmallette):
Here's a workaround:
{code}
gremlin> g.V().
......1> hasLabel("person").
......2> out("created").
......3> order().by(coalesce(values('name'),constant('x'))).
......4> choose(has("name"),values('name'),constant('x')).
......5> fold()
==>[lop,lop,lop,ripple,x]
{code}
> coalesce() creating unexpected results when used with order()
> -------------------------------------------------------------
>
> Key: TINKERPOP-2100
> URL: https://issues.apache.org/jira/browse/TINKERPOP-2100
> Project: TinkerPop
> Issue Type: Bug
> Components: process
> Affects Versions: 3.3.4
> Reporter: stephen mallette
> Assignee: Daniel Kuppitz
> Priority: Major
>
> Bug was originally reported here:
> https://stackoverflow.com/q/53482054/1831717
> demonstrated as:
> {code}
> gremlin> g.V().
> ......1> hasLabel("person").
> ......2> out("created").
> ......3> order().by("name").
> ......4> coalesce(values("name").fold(), constant("x")).
> ......5> fold()
> ==>[[lop,lop,lop],[lop,lop,lop],[lop,lop,lop],[ripple]]
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)