what is the {end time} for {James Comey} has {member of political party} as {independent politician} ?
When year did James Comey's service end?
What is the { end time } for { James Comey } as an { independent politician }?
SELECT ?k WHERE { ?c property:end_time ?k . resource:James_Comey property:member_of_political_party ?c . ?c property:member_of_political_party resource:independent_politician }
select distinct ?value  where {
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q167607> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P102> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> <http://wikidata.dbpedia.org/resource/Q327591> .
?statement <http://www.wikidata.org/entity/P582> ?value. 
} 

SELECT ?value WHERE { wd:Q167607 p:P102 ?s . ?s ps:P102 wd:Q327591 . ?s pq:P582 ?value}