LinguaLibre
Difference between revisions of "Speakers"
(Marked this version for translation) |
|||
(26 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | <query> | + | <languages/> |
− | select ?locutor ?locutorLabel | + | <translate> |
+ | <!--T:3--> | ||
+ | <query _pagination="50" locutor="item" locutorLabel="Speaker username" place="Place of residence"> | ||
+ | PREFIX wd: <http://www.wikidata.org/entity/> | ||
+ | PREFIX wdt: <http://www.wikidata.org/prop/direct/> | ||
+ | select distinct ?locutor ?locutorLabel ?place | ||
where { | where { | ||
?locutor prop:P2 entity:Q3 . | ?locutor prop:P2 entity:Q3 . | ||
− | SERVICE wikibase:label { | + | #extra:{"type": "wikibase-item", "filter":"Q4", "label": "P4", "multiple": true} ?locutor prop:P4 entity:[EXTRA] . |
− | bd:serviceParam wikibase:language " | + | ?locutor prop:P14 ?location . |
+ | BIND(uri(concat("http://www.wikidata.org/entity/", IF( isBLANK(?location), 'Q2', ?location ))) as ?locationItem). | ||
+ | |||
+ | SERVICE <https://query.wikidata.org/sparql> { | ||
+ | #extra:{"type":"wikidata", "label":"P14"} ?locationItem wdt:P131*/wdt:P131? wd:[EXTRA] . | ||
+ | ?locationItem rdfs:label ?place . | ||
+ | FILTER (LANG(?place) = "[AUTO_LANGUAGE]") . | ||
+ | } | ||
+ | SERVICE wikibase:label { | ||
+ | bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" . | ||
} | } | ||
} | } | ||
− | </query> | + | </query></translate> |