You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jena.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2020/03/02 16:53:00 UTC

[jira] [Commented] (JENA-1843) OpAsQuery: Wrong order of Extend/Bind

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

ASF subversion and git services commented on JENA-1843:
-------------------------------------------------------

Commit e76bb0902d1efbad820e577f04feca6b3553acd6 in jena's branch refs/heads/master from Andy Seaborne
[ https://gitbox.apache.org/repos/asf?p=jena.git;h=e76bb09 ]

Merge pull request #701 from afs/op-as-query

JENA-1843, JENA-1844: Fixes for OpAsQuery

> OpAsQuery: Wrong order of Extend/Bind
> -------------------------------------
>
>                 Key: JENA-1843
>                 URL: https://issues.apache.org/jira/browse/JENA-1843
>             Project: Apache Jena
>          Issue Type: Bug
>          Components: ARQ
>    Affects Versions: Jena 3.14.0
>            Reporter: Claus Stadler
>            Assignee: Andy Seaborne
>            Priority: Major
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> OpAsQuery breaks BINDs that depend on each other:
>  
> {code:java}
> Query expected = QueryFactory.create("SELECT *
> { ?s ?p ?o BIND(?s AS ?x) BIND(?x AS ?y) }
> ");
>  Query actual = OpAsQuery.asQuery(Algebra.compile(expected));
>  System.out.println(expected);
>  System.out.println(actual);
> {code}
> The two BIND statements incorrectly end up in reversed order - thus ?x is no longer bound in the result set:
> {code:java}
> expected: SELECT * WHERE { ?s ?p ?o BIND(?s AS ?x) BIND(?x AS ?y) }
> actual  : SELECT * WHERE { ?s ?p ?o BIND(?x AS ?y) BIND(?s AS ?x) }
> {code}
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)