What is the {taxon} with the {MAX(highest observed lifespan)} whose {subclass of} is {omnivore}  ?
What is the longest living omnivorous species?
Can you name the species of omnivore with the longest observed lifespan?
SELECT ?f WHERE { ?f rdf:type ontology:omnivore . ?f rdf:type ontology:taxon . ?f property:highest_observed_lifespan ?a }
select ?ent where {
?ent <http://www.wikidata.org/entity/P31> <http://wikidata.dbpedia.org/resource/Q16521>.

?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> ?ent .
?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P4214>.
?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> ?obj1.

?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> ?ent .
?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P279> .
?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> <http://wikidata.dbpedia.org/resource/Q164509> .

}
ORDER BY DESC(?obj1)
LIMIT 5
select ?ent where { ?ent wdt:P31 wd:Q16521 . ?ent wdt:P4214 ?obj . ?ent wdt:P279 wd:Q164509 } ORDER BY DESC(?obj)LIMIT 5 