Project:SPARQL/examples: Difference between revisions

Line 417: Line 417:
   ?district bnwdt:P33 ?county . #select counties
   ?district bnwdt:P33 ?county . #select counties
   ?county bnwdt:P33 ?region . #select region
   ?county bnwdt:P33 ?region . #select region
  FILTER NOT EXISTS {?region bnwdt:P117 "Q145" .} #filter out UK (where UK is sub-region of NI)
   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en-gb". }  
   SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en-gb". }  
}
}