query-fc9ed80ee0b40a432d49aeb02c6ea1d9
Propertiesinstance of (P31)located in the administrative territorial entity (P131)subclass of (P279)
Use at
- https://query.wikidata.org/sparql
PREFIX mwapi: <http://wikiba.se/ontology#>
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?itemLabel ?search ?countyLabel
WHERE {
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
VALUES ?search {
'Arroya Seco'
'Barrett'
'Bassano'
'Bear Valley'
'Big Rock Creek'
'Brush Breakwater'
'Capay'
'Clear Lake'
'Cuyamaca'
'Dominici Fill'
'Don Pedro'
'Dye Canon'
'Echo Lake'
'Escondido'
'Exchequer'
'Franklin Canyon'
'Hemet'
'Hodges'
'Indian Hill'
'La Grange'
'La Mesa'
'Laguna'
'Lookout'
'Melones'
'Middle Dam'
'Mockingbird'
'Mockingbird Canyon'
'Moore'
'Morgan Fill'
'New Eastwood'
'Oakdale'
'Old Mission'
'Otay'
'Pacino'
'Rairden Fill'
'Salter'
'San Fernando'
'San Mateo'
'Silver Flat'
'Strawberry Furrow'
'Sweetwater'
'Timber Crib'
'Tujonga'
'Van Giesen'
'Yorba' }
SERVICE wikibase:mwapi {
bd:serviceParam wikibase:endpoint "www.wikidata.org";
wikibase:api "EntitySearch";
mwapi:search ?search;
mwapi:language "en".
?item wikibase:apiOutputItem mwapi:item.
?num wikibase:apiOrdinal true.
}
# ?item wdt:P31 wd:Q12323
?item wdt:P31 ?type;
wdt:P131 ?county.
?type wdt:P279* wd:Q12323.
} ORDER BY ?search LIMIT 50
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v5("?county")
v2("?item"):::projected
v3("?num")
v2("?search"):::projected
v4("?type")
c7(["www.wikidata.org"]):::literal
c13(["mwapi:item"]):::iri
c11(["en"]):::literal
c2(["bd:serviceParam"]):::iri
c9(["EntitySearch"]):::literal
c15(["true^^xsd:boolean"]):::literal
c4(["#91;AUTO_LANGUAGE#93;,en"]):::literal
c19(["wd:Q12323"]):::iri
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c2 --"mwapi:language"--> c4
end
bind0[/VALUES ?search/]
bind0-->v2
bind00(["Arroya Seco"])
bind00 --> bind0
bind01(["Barrett"])
bind01 --> bind0
bind02(["Bassano"])
bind02 --> bind0
bind03(["Bear Valley"])
bind03 --> bind0
bind04(["Big Rock Creek"])
bind04 --> bind0
bind05(["Brush Breakwater"])
bind05 --> bind0
bind06(["Capay"])
bind06 --> bind0
bind07(["Clear Lake"])
bind07 --> bind0
bind08(["Cuyamaca"])
bind08 --> bind0
bind09(["Dominici Fill"])
bind09 --> bind0
bind010(["Don Pedro"])
bind010 --> bind0
bind011(["Dye Canon"])
bind011 --> bind0
bind012(["Echo Lake"])
bind012 --> bind0
bind013(["Escondido"])
bind013 --> bind0
bind014(["Exchequer"])
bind014 --> bind0
bind015(["Franklin Canyon"])
bind015 --> bind0
bind016(["Hemet"])
bind016 --> bind0
bind017(["Hodges"])
bind017 --> bind0
bind018(["Indian Hill"])
bind018 --> bind0
bind019(["La Grange"])
bind019 --> bind0
bind020(["La Mesa"])
bind020 --> bind0
bind021(["Laguna"])
bind021 --> bind0
bind022(["Lookout"])
bind022 --> bind0
bind023(["Melones"])
bind023 --> bind0
bind024(["Middle Dam"])
bind024 --> bind0
bind025(["Mockingbird"])
bind025 --> bind0
bind026(["Mockingbird Canyon"])
bind026 --> bind0
bind027(["Moore"])
bind027 --> bind0
bind028(["Morgan Fill"])
bind028 --> bind0
bind029(["New Eastwood"])
bind029 --> bind0
bind030(["Oakdale"])
bind030 --> bind0
bind031(["Old Mission"])
bind031 --> bind0
bind032(["Otay"])
bind032 --> bind0
bind033(["Pacino"])
bind033 --> bind0
bind034(["Rairden Fill"])
bind034 --> bind0
bind035(["Salter"])
bind035 --> bind0
bind036(["San Fernando"])
bind036 --> bind0
bind037(["San Mateo"])
bind037 --> bind0
bind038(["Silver Flat"])
bind038 --> bind0
bind039(["Strawberry Furrow"])
bind039 --> bind0
bind040(["Sweetwater"])
bind040 --> bind0
bind041(["Timber Crib"])
bind041 --> bind0
bind042(["Tujonga"])
bind042 --> bind0
bind043(["Van Giesen"])
bind043 --> bind0
bind044(["Yorba"])
bind044 --> bind0
subgraph s2["http://wikiba.se/ontology#mwapi"]
style s2 stroke-width:4px;
c2 --"mwapi:endpoint"--> c7
c2 --"mwapi:api"--> c9
c2 --"mwapi:search"--> v2
c2 --"mwapi:language"--> c11
v2 --"mwapi:apiOutputItem"--> c13
v3 --"mwapi:apiOrdinal"--> c15
end
v2 --"wdt:P31"--> v4
v2 --"wdt:P131"--> v5
v4 --"wdt:P279"--> c19