SELECT DISTINCT ?uri WHERE { ?uri <http://dbpedia.org/ontology/capital> <http://dbpedia.org/resource/Nicomedia> . ?uri <http://dbpedia.org/ontology/capital> <http://dbpedia.org/resource/History_of_Trier> . ?uri <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://dbpedia.org/ontology/Country>}
Which ancient country had capital as Nicomedia and History of Trier?
SELECT DISTINCT ?i WHERE { ?i rdf:type ontology:Country . ?i property:capital resource:Nicomedia . ?i property:capital resource:History_of_Trier }
Roman Empire
The country with capitals Nicomedia and History of Trier is [Roman Empire].
The country with the history of Nifedia and Trier is [the Roman Empire].