query-607ae79a9191a2b037c7b8d40a9b296d
TODO
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 psv: <http://www.wikidata.org/prop/statement/value/>
PREFIX psn: <http://www.wikidata.org/prop/statement/value-normalized/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?itemLabel ?area_value ?area_unit ?area_unitLabel ?faktor ?area_value_normalized ?area_unit_normalizedLabel
WHERE
{
values ?item {wd:Q1368230 wd:Q23066 wd:Q134902 wd:Q7808470 wd:Q826782 wd:Q853012 wd:Q43230752 wd:Q945555}
?item p:P2046 [
# use psv to get the value and unit as stored in Wikidata
psv:P2046 [wikibase:quantityAmount ?area_value; wikibase:quantityUnit ?area_unit] ;
# use psn to get a normalized value using the SI-unit for area
psn:P2046 [wikibase:quantityAmount ?area_value_normalized; wikibase:quantityUnit ?area_unit_normalized]
] .
?area_unit wdt:P2370 ?faktor .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
ORDER BY ?faktor
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v4("?area_unit"):::projected
v6("?area_unit_normalized")
v3("?area_value"):::projected
v5("?area_value_normalized"):::projected
v1("?faktor"):::projected
v2("?item"):::projected
a2((" "))
a1((" "))
a3((" "))
c8(["bd:serviceParam"]):::iri
c10(["#91;AUTO_LANGUAGE#93;,en"]):::literal
bind0[/VALUES ?item/]
bind0-->v2
bind00(["wd:Q1368230"])
bind00 --> bind0
bind01(["wd:Q23066"])
bind01 --> bind0
bind02(["wd:Q134902"])
bind02 --> bind0
bind03(["wd:Q7808470"])
bind03 --> bind0
bind04(["wd:Q826782"])
bind04 --> bind0
bind05(["wd:Q853012"])
bind05 --> bind0
bind06(["wd:Q43230752"])
bind06 --> bind0
bind07(["wd:Q945555"])
bind07 --> bind0
a1 --"wikibase:quantityAmount"--> v3
a1 --"wikibase:quantityUnit"--> v4
a2 --"p:statement/value/P2046"--> a1
a3 --"wikibase:quantityAmount"--> v5
a3 --"wikibase:quantityUnit"--> v6
a2 --"p:statement/value-normalized/P2046"--> a3
v2 --"p:P2046"--> a2
v4 --"p:direct/P2370"--> v1
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c8 --"wikibase:language"--> c10
end