You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jena.apache.org by "Andy Seaborne (JIRA)" <ji...@apache.org> on 2013/09/19 23:56:51 UTC
[jira] [Updated] (JENA-535) Algebra.toQuadForm() does not transform
Expressions in Optional clauses
[ https://issues.apache.org/jira/browse/JENA-535?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andy Seaborne updated JENA-535:
-------------------------------
Description:
Our internal testing has flagged up a failure in 2.11.0 in Algebra.toQuadForm() when applied to expressions within an OPTIONAL clause.
The query in question is as follows:
{noformat}
SELECT *
WHERE
{ ?s ?p ?o
OPTIONAL
{
FILTER NOT EXISTS {?s ?p ?o }
}
}
{noformat}
The algebra before calling Algebra.toQuadForm() is as follows:
{noformat}
(leftjoin
(bgp (triple ?s ?p ?o))
(table unit)
(notexists (bgp (triple ?s ?p ?o))))
{noformat}
The expected algebra is as follows:
{noformat}
(leftjoin
(quadpattern (quad <urn:x-arq:DefaultGraphNode> ?s ?p ?o))
(table unit)
(notexists (quadpattern (quad <urn:x-arq:DefaultGraphNode> ?s ?p ?o))))
{noformat}
The resulting algebra is as follows:
{noformat}
(leftjoin
(quadpattern (quad <urn:x-arq:DefaultGraphNode> ?s ?p ?o))
(table unit)
(notexists (bgp (triple ?s ?p ?o))))
{noformat}
It appears that the Transform Walkers visit the left and right Ops of the OpLeftJoin but not the ExprList that contains the E_NotExists.
was:
Our internal testing has flagged up a failure in 2.11.0 in Algebra.toQuadForm() when applied to expressions within an OPTIONAL clause.
The query in question is as follows:
SELECT *
WHERE
{ ?s ?p ?o
OPTIONAL
{
FILTER NOT EXISTS {?s ?p ?o }
}
}
The algebra before calling Algebra.toQuadForm() is as follows:
(leftjoin
(bgp (triple ?s ?p ?o))
(table unit)
(notexists (bgp (triple ?s ?p ?o))))
The expected algebra is as follows:
(leftjoin
(quadpattern (quad <urn:x-arq:DefaultGraphNode> ?s ?p ?o))
(table unit)
(notexists (quadpattern (quad <urn:x-arq:DefaultGraphNode> ?s ?p ?o))))
The resulting algebra is as follows:
(leftjoin
(quadpattern (quad <urn:x-arq:DefaultGraphNode> ?s ?p ?o))
(table unit)
(notexists (bgp (triple ?s ?p ?o))))
It appears that the Transform Walkers visit the left and right Ops of the OpLeftJoin but not the ExprList that contains the E_NotExists.
> Algebra.toQuadForm() does not transform Expressions in Optional clauses
> -----------------------------------------------------------------------
>
> Key: JENA-535
> URL: https://issues.apache.org/jira/browse/JENA-535
> Project: Apache Jena
> Issue Type: Bug
> Components: ARQ
> Affects Versions: Jena 2.11.0
> Reporter: Tracy Hartford
>
> Our internal testing has flagged up a failure in 2.11.0 in Algebra.toQuadForm() when applied to expressions within an OPTIONAL clause.
> The query in question is as follows:
> {noformat}
> SELECT *
> WHERE
> { ?s ?p ?o
> OPTIONAL
> {
> FILTER NOT EXISTS {?s ?p ?o }
> }
> }
> {noformat}
> The algebra before calling Algebra.toQuadForm() is as follows:
> {noformat}
> (leftjoin
> (bgp (triple ?s ?p ?o))
> (table unit)
> (notexists (bgp (triple ?s ?p ?o))))
> {noformat}
> The expected algebra is as follows:
> {noformat}
> (leftjoin
> (quadpattern (quad <urn:x-arq:DefaultGraphNode> ?s ?p ?o))
> (table unit)
> (notexists (quadpattern (quad <urn:x-arq:DefaultGraphNode> ?s ?p ?o))))
> {noformat}
> The resulting algebra is as follows:
> {noformat}
> (leftjoin
> (quadpattern (quad <urn:x-arq:DefaultGraphNode> ?s ?p ?o))
> (table unit)
> (notexists (bgp (triple ?s ?p ?o))))
> {noformat}
> It appears that the Transform Walkers visit the left and right Ops of the OpLeftJoin but not the ExprList that contains the E_NotExists.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira