【发布时间】:2015-08-31 11:06:54
【问题描述】:
假设我有以下数据集:
:a rdf:type :AClass
:a :hasName "a"^^xsd:string
:a :hasProperty :xa
:a :hasProperty :ya
:a :hasProperty :za
:b rdf:type :AClass
:b :hasName "b"^^xsd:string
:b :hasProperty :xb
:b :hasProperty :yb
:c rdf:type :AClass
:c :hasName "c"^^xsd:string
:c :hasProperty :xc
我想查询数据集以返回:AClass 实例的所有内容,但仅限于两个实例。我知道我必须使用LIMIT 关键字,并且我尝试了很多查询但没有成功。
换句话说,我想找回这个:
:a :hasName "a"^^xsd:string
:a :hasProperty :xa
:a :hasProperty :ya
:a :hasProperty :za
:b :hasName "b"^^xsd:string
:b :hasProperty :xb
:b :hasProperty :yb
如何将结果限制为 2 个实例的数量而不是 2 行的数量?
【问题讨论】:
标签: rdf sparql semantic-web owl sesame