What is {first minister} of {partner town} of {Hama} ?
Give me the name of the first minister of Hama.
Who is the first minister of Hama?
SELECT ?j WHERE { resource:Hama property:twinned_administrative_body ?u . ?u property:head_of_government ?j }
SELECT ?answer WHERE { ?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q173545> . ?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P190>. ?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> ?X . ?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> ?X. ?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P6> . ?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> ?answer . }
SELECT ?answer WHERE { wd:Q173545 wdt:P190 ?X . ?X wdt:P6 ?answer}
José Luis Martínez-Almeida