如果数据集是:
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix : <http://example.org/book/> .
@prefix ns: <http://example.org/ns#> .
:book1 dc:title "SPARQL Tutorial" .
:book2 dc:title "The Semantic Web" .
如何检查三联:book1 dc:title "SPARQL Tutorial" .
是否存在?
我可以SELECT ?book where {?book dc:title "SPARQL Tutorial"}
但我必须进行后期处理,以确定是否检索到'book1'!
答案 0 :(得分:4)
ASK { ?book dc:title "SPARQL Tutorial" }