query-e7a81ac5b6b5ea219ae4d4dd92625550
Propertiesinstance of (P31)subclass of (P279)located in the administrative territorial entity (P131)inception (P571)operator (P137)main regulatory text (P92)Commons category (P373)area (P2046)
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 psn: <http://www.wikidata.org/prop/statement/value-normalized/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT DISTINCT ?national_park_of_Australia ?national_park_of_AustraliaLabel ?administrative_areaLabel ?area ?establishedYear ?operatorLabel ?main_regulatory_text ?main_regulatory_textLabel ?commons_category_link WHERE {
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
?national_park_of_Australia wdt:P31 wd:Q18618819.
?national_park_of_Australia wdt:P31/wdt:P279* wd:Q17000624.
?national_park_of_Australia wdt:P131 ?administrative_area.
?administrative_area wdt:P31/wdt:P279* wd:Q178712.
OPTIONAL {
?national_park_of_Australia wdt:P571 ?established.
BIND(STR(YEAR(?established)) AS ?establishedYear).
}.
OPTIONAL { ?national_park_of_Australia wdt:P137 ?operator }.
OPTIONAL { ?national_park_of_Australia wdt:P92 ?main_regulatory_text }.
OPTIONAL { ?national_park_of_Australia p:P2046/psn:P2046/wikibase:quantityAmount ?area }.
OPTIONAL {
?national_park_of_Australia wdt:P373 ?commons_category.
BIND(CONCAT("https://commons.wikimedia.org/wiki/Category:", ?commons_category) AS ?commons_category_link).
}.
}
ORDER BY DESC(?area) ASC(?establishedYear) ASC(?national_park_of_AustraliaLabel)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v5("?administrative_area")
v1("?area"):::projected
v9("?commons_category")
v10("?commons_category_link"):::projected
v6("?established")
v7("?establishedYear"):::projected
v8("?main_regulatory_text"):::projected
v4("?national_park_of_Australia"):::projected
v3("?national_park_of_AustraliaLabel"):::projected
v7("?operator")
a1((" "))
a2((" "))
a3((" "))
a4((" "))
c10(["wd:Q178712"]):::iri
c8(["wd:Q17000624"]):::iri
c2(["bd:serviceParam"]):::iri
c6(["wd:Q18618819"]):::iri
c4(["#91;AUTO_LANGUAGE#93;,en"]):::literal
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c2 --"wikibase:language"--> c4
end
v4 --"p:direct/P31"--> c6
v4 --"p:direct/P31"--> a1
a1 --"p:direct/P279"--> c8
v4 --"p:direct/P131"--> v5
v5 --"p:direct/P31"--> a2
a2 --"p:direct/P279"--> c10
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v4 -."p:direct/P571".-> v6
bind0[/"str(year-from-dateTime(?established))"/]
v6 --o bind0
bind0 --as--o v7
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v4 -."p:direct/P137".-> v7
end
subgraph optional2["(optional)"]
style optional2 fill:#bbf,stroke-dasharray: 5 5;
v4 -."p:direct/P92".-> v8
end
subgraph optional3["(optional)"]
style optional3 fill:#bbf,stroke-dasharray: 5 5;
v4 -."p:P2046".-> a3
a3 --"p:statement/value-normalized/P2046"--> a4
a4 --"wikibase:quantityAmount"--> v1
end
subgraph optional4["(optional)"]
style optional4 fill:#bbf,stroke-dasharray: 5 5;
v4 -."p:direct/P373".-> v9
bind1[/"concat('https://commons.wikimedia.org/wiki/Category:',?commons_category)"/]
v9 --o bind1
bind1 --as--o v10
end