query-1b60181c8ad4bcf6ab273f6f87469910
title: Beatles Lieder SELECT ?page_title ?article (GROUP_CONCAT(DISTINCT ?komponist; SEPARATOR = ", ") AS ?komponisten) ?jahr ?album ?item WHERE { ?item wdt:P31 wd:Q105543609; wdt:P175 wd:Q1299; wdt:P407 wd:Q1860. ?article schema:about ?item; schema:isPartOf https://de.wikipedia.org/; schema:name ?page_title. OPTIONAL { ?item wdt:P577 ?year. } OPTIONAL { ?item wdt:P86 ?composer. } OPTIONAL { ?item wdt:P361 ?part_of. } BIND(YEAR(?year) AS ?jahr) SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". ?composer rdfs:label ?komponist. ?part_of rdfs:label ?album. } } GROUP BY ?page_title ?article ?jahr ?album ?item ORDER BY (?jahr) (?album)
Use at
- https://query.wikidata.org/sparql
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 rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX bd: <http://www.bigdata.com/rdf#>
#title: Beatles Lieder
SELECT ?page_title ?article (GROUP_CONCAT(DISTINCT ?komponist; SEPARATOR = ", ") AS ?komponisten) ?jahr ?album ?item WHERE {
?item wdt:P31 wd:Q105543609;
wdt:P175 wd:Q1299;
wdt:P407 wd:Q1860.
?article schema:about ?item;
schema:isPartOf <https://de.wikipedia.org/>;
schema:name ?page_title.
OPTIONAL { ?item wdt:P577 ?year. }
OPTIONAL { ?item wdt:P86 ?composer. }
OPTIONAL { ?item wdt:P361 ?part_of. }
BIND(YEAR(?year) AS ?jahr)
SERVICE wikibase:label {
bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en".
?composer rdfs:label ?komponist.
?part_of rdfs:label ?album.
}
}
GROUP BY ?page_title ?article ?jahr ?album ?item
ORDER BY (?jahr) (?album)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v2("?album"):::projected
v4("?article"):::projected
v7("?composer")
v3("?item"):::projected
v9("?jahr"):::projected
v9("?komponist"):::projected
v10("?komponisten")
v5("?page_title"):::projected
v8("?part_of")
v6("?year")
c9([https://de.wikipedia.org/]):::iri
c15(["bd:serviceParam"]):::iri
c2(["wd:Q105543609"]):::iri
c17(["#91;AUTO_LANGUAGE#93;,en"]):::literal
c4(["wd:Q1299"]):::iri
c6(["wd:Q1860"]):::iri
v3 --"wdt:P31"--> c2
v3 --"wdt:P175"--> c4
v3 --"wdt:P407"--> c6
v4 --"schema:about"--> v3
v4 --"schema:isPartOf"--> c9
v4 --"schema:name"--> v5
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v3 -."wdt:P577".-> v6
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v3 -."wdt:P86".-> v7
end
subgraph optional2["(optional)"]
style optional2 fill:#bbf,stroke-dasharray: 5 5;
v3 -."wdt:P361".-> v8
end
bind0[/"year-from-dateTime(?year)"/]
v6 --o bind0
bind0 --as--o v9
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c15 --"wikibase:language"--> c17
v7 --"rdfs:label"--> v9
v8 --"rdfs:label"--> v2
end
bind2[/"?komponist"/]
v9 --o bind2
bind2 --as--o v10