Question: Which states border Utah?
SPARQL query:
PREFIX res: <http://dbpedia.org/resource/>
PREFIX prop: <http://dbpedia.org/property/>
PREFIX yago: <http://dbpedia.org/class/yago/>
SELECT DISTINCT ?uri ?string
WHERE 
{
         {res:Kansas prop:north ?string.}
         UNION
         {res:Kansas prop:northeast ?string.}
         UNION
         {res:Kansas prop:south ?string.}
         UNION
         {res:Kansas prop:southeast ?string.}
         UNION
         {res:Kansas prop:east ?string.}
         UNION
         {res:Kansas prop:west ?string.}
         OPTIONAL { ?uri rdf:type yago:StatesOfTheUnitedStates .
                    ?uri prop:name ?string . }
}