Skip to content

Evaluation of GRAPH pattern ignores blank nodes as graph names #217

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
hartig opened this issue May 10, 2025 · 0 comments
Open

Evaluation of GRAPH pattern ignores blank nodes as graph names #217

hartig opened this issue May 10, 2025 · 0 comments

Comments

@hartig
Copy link
Contributor

hartig commented May 10, 2025

The definition of how to evaluate GRAPH patterns uses the following pseudo code for the case of GRAPH patterns with a variable rather than an IRI.

eval(D(G), Graph(var,P)) =
    Let R be the empty multiset
    foreach IRI i in D
        R := Union(R, Join( eval(D(D[i]), P) , Ω(?var->i) ) )
    the result is R

The foreach loop in the third line considers only IRIs as graph names in the queried dataset. Yet, given that we now have adopted the RDF Concepts notion of RDF dataset also for SPARQL, graph names may also be blank nodes. The current definition GRAPH pattern evaluation ignores this option.

We can easily fix this issue by extending the third line of the pseudo code above such that it considers blank nodes as well, but this requires also extending the definition of the notation D[i] as used in the fourth line. Additionally, it would be useful to make more explicit that the third line actually refers to the graph names in D.

Implementing this fix has to wait until after PR #216 has been merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant