what is the {end time} for {Susilo Bambang Yudhoyono} has {position held} as {President of Indonesia} ?
Susilo Bamban Yudhoyono was President of Indonesia until when?
When did Susilo Bambang Yudhoyono's term as President of Indonesia end?
SELECT ?y WHERE { ?k property:position_held resource:President_of_Indonesia . ?k property:end_time ?y . resource:Susilo_Bambang_Yudhoyono property:position_held ?k }
select distinct ?value  where {
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q57405> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P39> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> <http://wikidata.dbpedia.org/resource/Q11755916> .
?statement <http://www.wikidata.org/entity/P582> ?value. 
} 

SELECT ?value WHERE { wd:Q57405 p:P39 ?s . ?s ps:P39 wd:Q11755916 . ?s pq:P582 ?value}