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

Andy Seaborne commented on JENA-384:
------------------------------------

The new (2022) SPARQL APIs introduce \{{substitution}} to replace initial 
bindings. \{{substitution}} is syntactic replacement of variables by values 
(points 1 & 2 above) and happens before query execution planning. It also 
applies uniformly to local and remote whereas initial binding is a local-only 
and fragile mechanism.

 

> Interaction of optimization (TransformFilterEquality) and initial binding
> -------------------------------------------------------------------------
>
>                 Key: JENA-384
>                 URL: https://issues.apache.org/jira/browse/JENA-384
>             Project: Apache Jena
>          Issue Type: Bug
>          Components: ARQ, Optimizer
>    Affects Versions: ARQ 2.9.4, Jena 2.10.0
>            Reporter: Andy Seaborne
>            Priority: Major
>         Attachments: ReportSubstitueOptimize.java
>
>
> substitution is normally done after optimization so that it preserves the 
> semantics in case of complex optional situations. 
> The equality filter optimization eliminates code that can't generate a 
> solution (the variable is unbound in the subexpression)
> This can be unexpected but it's neither clearly right or clearly wrong. The 
> semantics of initial binding need clarifying; 
>    either 
>       pure substitution semantics, with the substitution applied before 
> optimization
>    or 
>       VALUES semantics (join with a data table) in which case elimination of 
> redundant pattern matching is correct.
> In the example, it's only an issue with URIs (reason?) but the general point 
> remains.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to