query-a8c9fa21d832d95b84a4fa00bb81f34e
TODO
Use at
- https://query.wikidata.org/sparql
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX prov: <http://www.w3.org/ns/prov#>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?st ?p ?ppLabel ?role
WHERE {
{
SELECT *
WHERE {
VALUES ?what { wd:Q205537 }
{ ?s ?p ?what .
?pp wikibase:statementProperty ?p .
BIND(?s AS ?st)
BIND("claim" AS ?role) }
UNION
{ ?s ?p ?what .
?pp wikibase:qualifier ?p .
BIND(?s as ?st)
BIND("qualifier" AS ?role) }
UNION
{ ?s ?p ?what .
?pp wikibase:reference ?p .
?st prov:wasDerivedFrom ?s .
BIND("reference" AS ?role) }
}
LIMIT 10000
} SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" . }
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v3("?p"):::projected
v4("?pp")
v7("?role"):::projected
v2("?s")
v7("?st"):::projected
v1("?what")
c6(["bd:serviceParam"]):::iri
c8(["#91;AUTO_LANGUAGE#93;,en"]):::literal
bind0[/VALUES ?what/]
bind0-->v1
bind00(["wd:Q205537"])
bind00 --> bind0
subgraph union0[" Union "]
subgraph union0l[" "]
style union0l fill:#abf,stroke-dasharray: 3 3;
subgraph union1[" Union "]
subgraph union1l[" "]
style union1l fill:#abf,stroke-dasharray: 3 3;
v2 -->v3--> v1
v4 --"wikibase:reference"--> v3
v7 --"prov:wasDerivedFrom"--> v2
bind1[/"'reference'"/]
bind1 --as--o v7
end
subgraph union1r[" "]
style union1r fill:#abf,stroke-dasharray: 3 3;
v2 -->v3--> v1
v4 --"wikibase:qualifier"--> v3
bind2[/"?s"/]
v2 --o bind2
bind2 --as--o v7
bind3[/"'qualifier'"/]
bind3 --as--o v7
end
union1r <== or ==> union1l
end
end
subgraph union0r[" "]
style union0r fill:#abf,stroke-dasharray: 3 3;
v2 -->v3--> v1
v4 --"wikibase:statementProperty"--> v3
bind4[/"?s"/]
v2 --o bind4
bind4 --as--o v7
bind5[/"'claim'"/]
bind5 --as--o v7
end
union0r <== or ==> union0l
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c6 --"wikibase:language"--> c8
end