query-c02f6b25e79d1d05d09407d9d3953eeb
TODO
Use at
- https://query.wikidata.org/sparql
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?item ?label ?authorlabel (count(?lang) as ?numWikipediaLanguages) WHERE
{
VALUES ?item {wd:Q22263533}
VALUES ?type {wd:Q571 wd:Q7725634}
?item wdt:P31 ?type .
?item wdt:P577 ?date .
?item wdt:P50 ?author .
OPTIONAL {?author wdt:P1559 ?authorlabel . filter(lang(?authorlabel) = "en")}
FILTER (?date > "1979-01-01T00:00:00Z"^^xsd:dateTime) .
?item rdfs:label ?label filter (lang(?label) = "en")
?item wdt:P407 wd:Q652.
?article schema:about ?item ;
schema:inLanguage ?lang ;
schema:isPartOf [ wikibase:wikiGroup "wikipedia" ] .
} group by ?item ?label ?authorlabel
ORDER BY DESC(?numWikipediaLanguages)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v8("?article")
v7("?author")
v4("?authorlabel"):::projected
v3("?date")
v5("?item"):::projected
v2("?label"):::projected
v9("?lang"):::projected
v10("?numWikipediaLanguages")
v6("?type")
a1((" "))
c9(["wd:Q652"]):::iri
c13(["wikipedia"]):::literal
f0[["?label = 'en'"]]
f0 --> v2
f1[["?date > '1979-01-01T00:00:00Z^^xsd:dateTime'"]]
f1 --> v3
bind2[/VALUES ?item/]
bind2-->v5
bind20(["wd:Q22263533"])
bind20 --> bind2
bind3[/VALUES ?type/]
bind3-->v6
bind30(["wd:Q571"])
bind30 --> bind3
bind31(["wd:Q7725634"])
bind31 --> bind3
v5 --"wdt:P31"--> v6
v5 --"wdt:P577"--> v3
v5 --"wdt:P50"--> v7
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v7 -."wdt:P1559".-> v4
end
v5 --"rdfs:label"--> v2
v5 --"wdt:P407"--> c9
v8 --"schema:about"--> v5
v8 --"schema:inLanguage"--> v9
a1 --"wikibase:wikiGroup"--> c13
v8 --"schema:isPartOf"--> a1
bind5[/"count(?lang)"/]
v9 --o bind5
bind5 --as--o v10