query-3d3066a4af7ec24bc09cf0721dc5fa87

rq turtle/ttl

TODO

Use at

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 bd: <http://www.bigdata.com/rdf#>
#defaultView:Table;
#------------------------------------------------------------------------------------
# opera singers who are sopranos with article in English Wikipedia
#------------------------------------------------------------------------------------
SELECT DISTINCT ?item ?itemLabel ?itemDescription ?article_en ?article_de  
WHERE {
  ?item wdt:P31 wd:Q5.                # is human
  ?item wdt:P106 wd:Q2865819.         # and occupatition is opera singer
  ?item wdt:P412 wd:Q30903.           # and voice type is soprano

  ?article_en schema:about ?item.
  ?article_en schema:isPartOf <https://en.wikipedia.org/>.     # and has article in English

  OPTIONAL {
    ?article_de schema:about ?item.
    ?article_de schema:isPartOf <https://de.wikipedia.org/>.   # and maybe article in German
  }

  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
order by ?itemLabel

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v4("?article_de"):::projected v3("?article_en"):::projected v2("?item"):::projected v1("?itemLabel"):::projected c10([https://de.wikipedia.org/]):::iri c6(["wd:Q30903"]):::iri c9([https://en.wikipedia.org/]):::iri c12(["bd:serviceParam"]):::iri c2(["wd:Q5"]):::iri c14(["#91;AUTO_LANGUAGE#93;,en"]):::literal c4(["wd:Q2865819"]):::iri v2 --"wdt:P31"--> c2 v2 --"wdt:P106"--> c4 v2 --"wdt:P412"--> c6 v3 --"schema:about"--> v2 v3 --"schema:isPartOf"--> c9 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v4 -."schema:about".-> v2 v4 --"schema:isPartOf"--> c10 end subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c12 --"wikibase:language"--> c14 end