What is {instance of} of {Grand Duchy of Lithuania} that is {end time} is {1795-0-0} ?
What occured in Lithuania in 1795?
What happened in Grand Duchy of Lithuania in 1795-0-0?
SELECT ?t WHERE { resource:Grand_Duchy_of_Lithuania rdf:type ?z . FILTER ( CONTAINS ( YEAR ( ?j ) , '1795' ) ) . ?z rdf:type ?t . ?z property:end_time ?j }
select distinct ?obj  where {
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q49683> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P31> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> ?obj .
?statement <http://www.wikidata.org/entity/P582> <1795-0-0>
} 

SELECT ?obj WHERE { wd:Q49683 p:P31 ?s . ?s ps:P31 ?obj . ?s pq:P582 ?x filter(contains(YEAR(?x),'1795')) }