What is {spouse} of {Mahmoud Ahmadinejad} that is {start time} is {1981-6-12} ?
To whom did Mahmoud Ahmadinejad become espoused to on June 12, 2981?
Who did Mahmoud Ahmadinejad marry on June 12, 2981?
SELECT ?p WHERE { resource:Mahmoud_Ahmadinejad property:spouse ?c . ?c property:spouse ?p . ?c property:start_time ?w . FILTER ( CONTAINS ( YEAR ( ?w ) , '1981' ) ) }
select distinct ?obj  where {
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q34448> .
?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> <1981-6-12>
} 

SELECT ?obj WHERE { wd:Q34448 p:P26 ?s . ?s ps:P26 ?obj . ?s pq:P580 ?x filter(contains(YEAR(?x),'1981')) }