Details

      Description

      The following query

      SELECT *
      WHERE {
        SELECT ?X {
          ?X :p2 :o2 .
        }
        {{ BIND(?X as ?new) } UNION { ?X :p :o }}
      }
      

      is rewritten (by the new JoinGroupOrderOptimizer) as

      SELECT *
      WHERE {
       {{ BIND(?X as ?new) } UNION { ?X :p :o }}
        SELECT ?X {
          ?X :p2 :o2 .
        }
      }
      

      The problem is that the binding of ?new requires ?X to be bound, i.e. the UNION node must be evaluated after the BIND node. The optimizer needs to be adjusted to take such recursive binding requirements into account.

        Activity

        Hide
        michaelschmidt michaelschmidt added a comment -

        Resolved in branch req_bindings_order. The fix is essentially checking for nodes that have required bindings that cannot be satisfied from inside. If such bindings exist, the nodes are ordered by requirement constraint in the given partition.

        CI ran through, merging into master.

        Show
        michaelschmidt michaelschmidt added a comment - Resolved in branch req_bindings_order. The fix is essentially checking for nodes that have required bindings that cannot be satisfied from inside. If such bindings exist, the nodes are ordered by requirement constraint in the given partition. CI ran through, merging into master.

          People

          • Assignee:
            michaelschmidt michaelschmidt
            Reporter:
            michaelschmidt michaelschmidt
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: