我用他们的名字查询一些城市。
这很好用。现在,当我看到这个:https://www.wikidata.org/wiki/Q729978
我可以看到没有西班牙名字,但我得到了#34; Mediolanum"
为什么我会到达那里?我怎么能改变它?
这是我的查询
SELECT DISTINCT ?city ?label ?population WHERE {
VALUES (?city) { (wd:Q729978) }
?city rdfs:label ?label
FILTER(LANG(?label) IN ("de","en","es","fr","it","pl","cs","hr","hu","nl","ru","tr","ro"))
}
回复是
{
"head" : {
"vars" : [ "city", "label", "population" ]
},
"results" : {
"bindings" : [ {
"city" : {
"type" : "uri",
"value" : "http://www.wikidata.org/entity/Q729978"
},
"label" : {
"xml:lang" : "de",
"type" : "literal",
"value" : "Mediolanum"
}
}, {
"city" : {
"type" : "uri",
"value" : "http://www.wikidata.org/entity/Q729978"
},
"label" : {
"xml:lang" : "en",
"type" : "literal",
"value" : "Mediolanum"
}
}, {
"city" : {
"type" : "uri",
"value" : "http://www.wikidata.org/entity/Q729978"
},
"label" : {
"xml:lang" : "nl",
"type" : "literal",
"value" : "Mediolanum"
}
}, {
"city" : {
"type" : "uri",
"value" : "http://www.wikidata.org/entity/Q729978"
},
"label" : {
"xml:lang" : "es",
"type" : "literal",
"value" : "Mediolanum"
}
}, {
"city" : {
"type" : "uri",
"value" : "http://www.wikidata.org/entity/Q729978"
},
"label" : {
"xml:lang" : "fr",
"type" : "literal",
"value" : "Mediolanum"
}
}, {
"city" : {
"type" : "uri",
"value" : "http://www.wikidata.org/entity/Q729978"
},
"label" : {
"xml:lang" : "hu",
"type" : "literal",
"value" : "Mediolanum"
}
}, {
"city" : {
"type" : "uri",
"value" : "http://www.wikidata.org/entity/Q729978"
},
"label" : {
"xml:lang" : "it",
"type" : "literal",
"value" : "Mediolanum"
}
}, {
"city" : {
"type" : "uri",
"value" : "http://www.wikidata.org/entity/Q729978"
},
"label" : {
"xml:lang" : "hr",
"type" : "literal",
"value" : "Mediolan"
}
}, {
"city" : {
"type" : "uri",
"value" : "http://www.wikidata.org/entity/Q729978"
},
"label" : {
"xml:lang" : "ru",
"type" : "literal",
"value" : "Медиоланум"
}
} ]
}
}