query-5cae74247917391cd84acdb772c215a3
]reply[03:18, 22 July 2019 (UTC)) talk (99of9. May be useful (without the filters) for finding alternate labels once items are associated with WD. --SCOT SPARQL endpointat the For example, some are multilingual already:
Use at
- https://query.wikidata.org/sparql
PREFIX :<http://www.w3.org/2004/02/skos/core#>
SELECT ?uri (SAMPLE(str(?enlab)) as ?prefLabel) (COUNT(?lab) AS ?count)
WHERE{
{?uri :prefLabel ?enlab .}
FILTER(lang(?enlab)='en')
{?uri :prefLabel ?lab .}
#UNION{?uri :altLabel ?lab .}
}
GROUP BY ?uri
ORDER BY DESC(?count)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v6("?count")
v2("?enlab"):::projected
v4("?lab"):::projected
v5("?prefLabel")
v3("?uri"):::projected
f0[["?enlab = 'en'"]]
f0 --> v2
v3 --http://www.w3.org/2004/02/skos/core#prefLabel--> v2
v3 --http://www.w3.org/2004/02/skos/core#prefLabel--> v4
bind3[/"sample(str(?enlab))"/]
v2 --o bind3
bind3 --as--o v5
bind4[/"count(?lab)"/]
v4 --o bind4
bind4 --as--o v6