What is {lives in} of {holds position} of {Lech Kaczyński} ?
Where does the holder of the position of Lech Kaczynski live?
Where does the holder of the position of Lech Kaczynski live?
SELECT ?b WHERE { ?q property:official_residence ?b . resource:Lech_Kaczyński property:position_held ?q }
SELECT ?answer WHERE { ?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q2757> . ?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P39>. ?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/P263> . ?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> ?answer . }
SELECT ?answer WHERE { wd:Q2757 wdt:P39 ?X . ?X wdt:P263 ?answer}
Presidential Palace