Re: Re: Undesirable SPARQL Jena Query Pattern Behavior with Optionals

2021-08-05 Thread Marco Neumann
Thank you for the link Lorenz. Yes it behaves the same with the same data, in my test it had a different dataset where ?xLabel was bound but with no matching ?x variable. Someone has recently elaborated on this with regards to Jena here. https://newbedev.com/sparql-optional-query On Thu, Aug 5,

Re: Re: Undesirable SPARQL Jena Query Pattern Behavior with Optionals

2021-08-05 Thread Lorenz Buehmann
That shouldn't happen for Blazegraph, especially as they even have a blog entry for this topic, dubbed "order matters": https://github.com/blazegraph/database/wiki/SPARQL_Order_Matters You can check the Blazegraph query plan as well, just put =details to the request URL You can also try to

Re: Undesirable SPARQL Jena Query Pattern Behavior with Optionals

2021-08-03 Thread Marco Neumann
OK yes, thank you for the algebra hint and implicit empty graph pattern Andy. Blazegraph has thrown me off here since it seems to interpret the query differently. without preserving the table unit on the left hand side I presume. On Tue, Aug 3, 2021 at 6:20 PM Andy Seaborne wrote: > > > On

Re: Undesirable SPARQL Jena Query Pattern Behavior with Optionals

2021-08-03 Thread Andy Seaborne
On 03/08/2021 17:38, Marco Neumann wrote: I have just noticed that the following query pattern with optionals yields undesirable SPARQL query results if the variable (?xLabel) isn't bound. Let the data be: :x :p :y SELECT ?x WHERE{ OPTIONAL{ ?x rdfs:label ?xLabel.} ?x :p ?y. } (join