query-33090320131693eddae8ae8cc25c5a77

rq turtle/ttl

Art works by Bauer without a "depicts" property, but a separate work has the same name and a depiction

Use at

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX prov: <http://www.w3.org/ns/prov#>
PREFIX pr: <http://www.wikidata.org/prop/reference/>
PREFIX p: <http://www.wikidata.org/prop/>
SELECT ?item2 ("P180" as ?prop) ?species ("S854" as ?ref) ?cite WHERE {
?item1 wdt:P170 wd:Q79012. 
?item2 wdt:P170 wd:Q79012.
?item1 p:P180 [ps:P180 ?species; prov:wasDerivedFrom/pr:P854 ?cite]
MINUS {?item2 wdt:P180 []}
?item1 rdfs:label ?name.
?item2 rdfs:label ?name
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v4("?cite"):::projected v1("?item1") v2("?item2"):::projected v5("?name") v6("?prop") v7("?ref") v3("?species"):::projected a3((" ")) a1((" ")) a2((" ")) c2(["wd:Q79012"]):::iri v1 --"p:direct/P170"--> c2 v2 --"p:direct/P170"--> c2 a1 --"p:statement/P180"--> v3 a1 --"prov:wasDerivedFrom"--> a2 a2 --"p:reference/P854"--> v4 v1 --"p:P180"--> a1 subgraph minus0["MINUS"] style minus0 stroke-width:6px,fill:pink,stroke:red; v2 --"p:direct/P180"--> a3 end v1 --"rdfs:label"--> v5 v2 --"rdfs:label"--> v5 bind1[/"'P180'"/] bind1 --as--o v6 bind2[/"'S854'"/] bind2 --as--o v7