query-1a4a7097be20fabb6554ae28ce55ba00
TODO
Use at
- https://query.wikidata.org/sparql
PREFIX mwapi: <http://wikiba.se/ontology#>
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX schema: <http://schema.org/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT distinct ?item ?itemLabel ?WP_EN_name ?simple_article ?simple_sitelink where
{
SERVICE wikibase:mwapi {
bd:serviceParam wikibase:endpoint "en.wikipedia.org";
wikibase:api "Generator";
mwapi:generator "categorymembers";
mwapi:gcmtitle "Category:Meitei people" ; # specifically here
mwapi:gcmprop "ids|title|type";
mwapi:gcmlimit "max".
# out
?WP_EN_name wikibase:apiOutput mwapi:title. # en-wikipedia article / category name
?item wikibase:apiOutputItem mwapi:item. # wikidata QId for the person's item
}
filter(bound(?item))
OPTIONAL { ?simple_article schema:about ?item ;
schema:isPartOf <https://simple.wikipedia.org/> ;
schema:name ?simple_sitelink . }
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v2("?WP_EN_name"):::projected
v1("?item"):::projected
v3("?simple_article"):::projected
v4("?simple_sitelink"):::projected
c18(["mwapi:item"]):::iri
c4(["en.wikipedia.org"]):::literal
c2(["bd:serviceParam"]):::iri
c21([https://simple.wikipedia.org/]):::iri
c14(["max"]):::literal
c8(["categorymembers"]):::literal
c10(["Category:Meitei people"]):::literal
c25(["#91;AUTO_LANGUAGE#93;,en"]):::literal
c16(["mwapi:title"]):::iri
c12(["ids|title|type"]):::literal
c6(["Generator"]):::literal
f0[["bound(?item)"]]
f0 --> v1
subgraph s1["http://wikiba.se/ontology#mwapi"]
style s1 stroke-width:4px;
c2 --"mwapi:endpoint"--> c4
c2 --"mwapi:api"--> c6
c2 --"mwapi:generator"--> c8
c2 --"mwapi:gcmtitle"--> c10
c2 --"mwapi:gcmprop"--> c12
c2 --"mwapi:gcmlimit"--> c14
v2 --"mwapi:apiOutput"--> c16
v1 --"mwapi:apiOutputItem"--> c18
end
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v3 -."schema:about".-> v1
v3 --"schema:isPartOf"--> c21
v3 --"schema:name"--> v4
end
subgraph s2["http://wikiba.se/ontology#label"]
style s2 stroke-width:4px;
c2 --"mwapi:language"--> c25
end