what is the {point in time} for {Mato Grosso} has {contains administrative territorial entity} as {Cuiabá} ?
In what year was Cuiba became annexed to Mato Grosso?
When did Cuiaba become part of Mato Grosso ?
SELECT ?h WHERE { ?g property:point_in_time ?h . resource:Mato_Grosso property:contains_administrative_territorial_entity ?g . ?g property:contains_administrative_territorial_entity resource:Cuiabá }
select distinct ?value  where {
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q42824> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P150> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> <http://wikidata.dbpedia.org/resource/Q170762> .
?statement <http://www.wikidata.org/entity/P585> ?value. 
} 

SELECT ?value WHERE { wd:Q42824 p:P150 ?s . ?s ps:P150 wd:Q170762 . ?s pq:P585 ?value}