考虑以下脚本:
PREFIX category: <http://dbpedia.org/resource/Category:>
PREFIX dcterms: <http://purl.org/dc/terms/>
PREFIX dbpedia: <http://dbpedia.org/ontology/>
SELECT DISTINCT *
WHERE {
?s dcterms:subject category:Living_people .
?s foaf:name ?name
}
LIMIT 10000
运行它时,我得到这样的结果:
Sir Alexander Chapman Ferguson
Sir Alex Ferguson
尽管它们是不同的条目,但它们绝对是相同的实体。所以我想在处理 SPARQL 端点时减少输出,即我想避免编辑输出数据,因为在这种情况下它可能具有挑战性。你能帮我解决这个问题吗?我的查询中应该修复什么?