Incorrect variable bindings with subqueries

Description

Hi Jeen,

I could reproduce the behaviour for https://openrdf.atlassian.net/browse/SES-2099 with a much simpler query; you'll see that each result binds ct01 with a different bnode.

If I'm not mistaken, the query should be equivalent with this one which actually works as expected :

meaning the algebra should first create a SingetonSet then extend it with the BIND and only then do the join so the variable ct01 should be bound to the same bnode for each result of the subquery.

So it seems that evaluating the subquery first (which is indeed required by the recommendation) does not respect the evaluation or join orders of the preceding graph patterns.

Environment

None

Status

Assignee

Jeen Broekstra

Reporter

Max

Labels

Components

Affects versions

Priority

Critical
Configure