What is {spouse} of {Marilyn Monroe} and {end time}
Who is Marilyn Monroe's husband and when did they give up their marriage?
Who is Marilyn Monroe's husband and when did they end their marriage?
SELECT ?w ?k WHERE { ?j property:spouse ?k . ?j property:end_time ?w . . resource:Marilyn_Monroe property:spouse ?j }
select distinct ?dataprop1 ?obj where { ?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q4616> . ?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P26> . ?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> ?obj . ?statement <http://www.wikidata.org/entity/P580> ?dataprop1 . } 
SELECT ?value1 ?obj WHERE { wd:Q4616 p:P26 ?s . ?s ps:P26 ?obj . ?s pq:P582 ?value1 . }