Regression When Checking for Reflexive Property

Description

When the same variable is used both in the subject and object position of a basic graph pattern, only one needs to match for the query to succeed. However, Sesame 2.6.10 would only match if both values were the same. See below for a better explanation. The following test case passed in 2.6.10 and fails in 2.7.0.

testCon.add(alice, publisher, bob);

StringBuilder queryBuilder = new StringBuilder();
queryBuilder.append("PREFIX dc: <http://purl.org/dc/elements/1.1/> ");
queryBuilder.append("SELECT ?publisher ");
queryBuilder.append("{ ?publisher dcublisher ?publisher }");

testCon.prepareTupleQuery(QueryLanguage.SPARQL, queryBuilder.toString()).evaluate(
new TupleQueryResultHandlerBase() {
public void handleSolution(BindingSet bindingSet)
throws TupleQueryResultHandlerException
{
fail("nobody is self published");
}
});

Environment

None

Status

Assignee

James Leigh

Reporter

James Leigh

Labels

None

Components

Fix versions

Affects versions

Priority

Blocker
Configure