【发布时间】:2015-11-03 16:04:42
【问题描述】:
我想从欧洲议会中提取有关特定议程项目的演讲,可通过此处的 SPARQL 界面访问这些演讲:http://linkedpolitics.ops.few.vu.nl/user/query
数据库的架构在这里找到:http://linkedpolitics.ops.few.vu.nl/home
通过以下查询
SELECT ?speaker ?given ?surname ?acronym ?text ?partyLabel ?type
WHERE {
<http://purl.org/linkedpolitics/eu/plenary/2010-12-16_AgendaItem_4> dcterms:hasPart ?speech.
?speech lpv:speaker ?speaker.
?speaker foaf:givenName ?given.
?speaker foaf:familyName ?surname.
?speaker lpv:countryOfRepresentation ?country.
?country lpv:acronym ?acronym.
?speech lpv:translatedText ?text.
?speaker lpv:politicalFunction ?func.
?func lpv:institution ?institution.
?institution rdfs:label ?partyLabel.
?institution rdf:type ?type.
FILTER(langMatches(lang(?text), "en"))
}
我得到了我想要的信息,但所有行都重复了好几次。当我试图通过看起来的政治功能访问政党标签时,就会发生这种情况。如何仅获取唯一行?首先出现重复的原因是什么?
【问题讨论】:
-
我遇到了类似的问题,我找到了解决方案:stackoverflow.com/questions/28988702/…