query-536d4754eb0d5f0392f32e8594e9615f
Tatort with team
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 rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX bd: <http://www.bigdata.com/rdf#>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX v: <http://www.wikidata.org/prop/statement/>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
SELECT ?tatortWithLabel (MIN(?publication) AS ?aired) ?case ?ordinal ?film ?title (GROUP_CONCAT(DISTINCT(?screenwriter);separator=", ") AS ?screenwriters) (GROUP_CONCAT(DISTINCT(?director);separator=", ") AS ?directors) (SAMPLE(?runtime) AS ?runtime) (SAMPLE(?imdb) AS ?imdb) WHERE {
?tatortWith wdt:P31 wd:Q5398426 . ?tatortWith wdt:P361 wd:Q689438 .
?film p:P179 ?series . ?series v:P179 wd:Q689438 . ?series pq:P1545 ?ordinal .
?film p:P179 ?team . ?team v:P179 ?tatortWith . ?team pq:P1545 ?case .
?film wdt:P1476 ?title
OPTIONAL{?film wdt:P57 ?dir . ?dir rdfs:label ?director . FILTER(lang(?director) = "de")}
OPTIONAL{?film wdt:P58 ?screen . ?screen rdfs:label ?screenwriter . FILTER(lang(?screenwriter) = "de")}
OPTIONAL{?film wdt:P345 ?imdb}
OPTIONAL{?film wdt:P577 ?publication}
OPTIONAL{?film wdt:P2047 ?runtime}
SERVICE wikibase:label { bd:serviceParam wikibase:language "de" }
}
GROUP BY ?tatortWith ?tatortWithLabel ?film ?title ?ordinal ?case
ORDER BY ?tatortWithLabel ASC(xsd:integer(?case))
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v16("?aired")
v2("?case"):::projected
v11("?dir")
v4("?director"):::projected
v18("?directors")
v6("?film"):::projected
v19("?imdb"):::projected
v8("?ordinal"):::projected
v14("?publication"):::projected
v19("?runtime"):::projected
v12("?screen")
v3("?screenwriter"):::projected
v17("?screenwriters")
v7("?series")
v5("?tatortWith")
v1("?tatortWithLabel"):::projected
v9("?team")
v10("?title"):::projected
c1(["de"]):::literal
c5(["wd:Q689438"]):::iri
c17(["bd:serviceParam"]):::iri
c3(["wd:Q5398426"]):::iri
v5 --"p:direct/P31"--> c3
v5 --"p:direct/P361"--> c5
v6 --"p:P179"--> v7
v7 --"p:statement/P179"--> c5
v7 --"p:qualifier/P1545"--> v8
v6 --"p:P179"--> v9
v9 --"p:statement/P179"--> v5
v9 --"p:qualifier/P1545"--> v2
v6 --"p:direct/P1476"--> v10
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v6 -."p:direct/P57".-> v11
v11 --"rdfs:label"--> v4
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v6 -."p:direct/P58".-> v12
v12 --"rdfs:label"--> v3
end
subgraph optional2["(optional)"]
style optional2 fill:#bbf,stroke-dasharray: 5 5;
v6 -."p:direct/P345".-> v19
end
subgraph optional3["(optional)"]
style optional3 fill:#bbf,stroke-dasharray: 5 5;
v6 -."p:direct/P577".-> v14
end
subgraph optional4["(optional)"]
style optional4 fill:#bbf,stroke-dasharray: 5 5;
v6 -."p:direct/P2047".-> v19
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c17 --"wikibase:language"--> c1
end
bind5[/"min(?publication)"/]
v14 --o bind5
bind5 --as--o v16
bind6[/"?screenwriter"/]
v3 --o bind6
bind6 --as--o v17
bind7[/"?director"/]
v4 --o bind7
bind7 --as--o v18
bind8[/"sample(?runtime)"/]
v19 --o bind8
bind8 --as--o v19
bind9[/"sample(?imdb)"/]
v19 --o bind9
bind9 --as--o v19