SPARQL 1.1 entailment regimes and query with FROM clause (follow-up)

浪子不回头ぞ 提交于 2019-12-11 12:07:48

问题


This is a follow-up question from SPARQL 1.1 entailment regimes and query with FROM clause

I'm currently documenting/testing about SPARQL 1.1 entailment regimes and the recommendation repeatedly states that

The scoping graph is graph-equivalent to the active graph...

So it would seems that the inference scoping graph depends on the query.

The question is: does the scoping graph stems from the query's dataset (FROM/FROM NAMED clauses) or does it refer to the real current active graph context for the triple pattern being evaluated ?

With the following graphs

# Named graph: <urn:rdfs-schema-graph>
@prefix ex:<http://www.example.org/> .
ex:Article rdfs:subClassOf ex:Publication .
ex:publishes rdfs:range ex:Publication .

# Named graph: <urn:data-graph>
@prefix ex:<http://www.example.org/> .
ex:book1 a ex:Publication .
ex:book2 a ex:Article .
ex:MITPress ex:publishes ex:book3 .

What should the following query return (here under RDFS-entailment regime, for instance) and according to the recommendation ?

PREFIX ex: <http://www.example.org/>
SELECT ?s 
FROM <urn:rdfs-schema-graph>
FROM NAMED <urn:data-graph>
WHERE {
  GRAPH <urn:data-graph> {
    ?s a ex:Publication .
  }
}

should I get back all three resources:

<http://www.example.org/book1>
<http://www.example.org/book2>
<http://www.example.org/book3>

or just

<http://www.example.org/book1>

since the active graph on the triple pattern is scoped to the NAMED graph while inferencing axioms are "located" in the default graph ?

Thanks for your insight,

Max.

来源:https://stackoverflow.com/questions/28436622/sparql-1-1-entailment-regimes-and-query-with-from-clause-follow-up

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!