query-3ee1b2921d5d5be8f025f1c8922a91a6

rq turtle/ttl

Propertiesauthor (P50)instance of (P31)subclass of (P279)occupation (P106)

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#>
SELECT DISTINCT ?work ?workLabel ?author ?authorLabel ?article WHERE {
?work wdt:P50 ?author ;
       wdt:P31/wdt:P279? wd:Q5185279. # ?work is a poem
?article schema:about ?work;
    schema:isPartOf <https://en.wikipedia.org/> .
MINUS {?author wdt:P106 wd:Q49757} # ?author is not listed as a poet
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],mul,en" }
} ORDER BY ?authorLabel

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v4("?article"):::projected v3("?author"):::projected v1("?authorLabel"):::projected v2("?work"):::projected a1((" ")) c9(["wd:Q49757"]):::iri c13(["#91;AUTO_LANGUAGE#93;,mul,en"]):::literal c7([https://en.wikipedia.org/]):::iri c11(["bd:serviceParam"]):::iri c3(["wd:Q5185279"]):::iri v2 --"wdt:P50"--> v3 v2 --"wdt:P31"--> a1 subgraph union0[" Union "] subgraph union0l[" "] style union0l fill:#abf,stroke-dasharray: 3 3; a1 --"wdt:P279"--> c3 end subgraph union0r[" "] style union0r fill:#abf,stroke-dasharray: 3 3; end union0r <== or ==> union0l end v4 --"schema:about"--> v2 v4 --"schema:isPartOf"--> c7 subgraph minus0["MINUS"] style minus0 stroke-width:6px,fill:pink,stroke:red; v3 --"wdt:P106"--> c9 end subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c11 --"wikibase:language"--> c13 end