We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Filters in subqueries only appear to work correctly if they in the first subquery. I put together a several small examples to show the problem.
[Again, uploading problems - I'll put the example in a separate comment.]
The text was updated successfully, but these errors were encountered:
import rdflib dataGraph = rdflib.Graph() print "SINGLE QUERY" query = """SELECT ?this WHERE { VALUES ?this { <http://ex.com/a> "HI" } FILTER ( ! isBlank(?this) ) }""" result = dataGraph.query(query) for row in result : print row assert len(result) > 0 print "NO FILTER" query = """ SELECT ?this WHERE { { SELECT ?this WHERE { VALUES ?this { <http://ex.com/a> "HI" } } } { SELECT ?this WHERE { VALUES ?this { <http://ex.com/a> "HI" } } } }""" result = dataGraph.query(query) for row in result : print row assert len(result) > 0 print "FILTER in first subquery" query = """ SELECT ?this WHERE { { SELECT ?this WHERE { VALUES ?this { <http://ex.com/a> "HI" } FILTER ( isIRI(?this) ) } } { SELECT ?this WHERE { VALUES ?this { <http://ex.com/a> "HI" } } } }""" result = dataGraph.query(query) for row in result : print row assert len(result) > 0 print "FILTER in second subquery" query = """ SELECT ?this WHERE { { SELECT ?this WHERE { VALUES ?this { <http://ex.com/a> "HI" } } } { SELECT ?this WHERE { VALUES ?this { <http://ex.com/a> "HI" } FILTER ( isIRI(?this) ) } } }""" result = dataGraph.query(query) for row in result : print row assert len(result) > 0
Sorry, something went wrong.
Thanks a lot for a very clearly diagnosed problem @pfps !
Fixed in acc6ed3
No branches or pull requests
Filters in subqueries only appear to work correctly if they in the first subquery.
I put together a several small examples to show the problem.
[Again, uploading problems - I'll put the example in a separate comment.]
The text was updated successfully, but these errors were encountered: