the whirlpool is under which galaxy classification code?
Entity
m.0cgl5wl
SA(s)bc pec
class entity
astronomy.galaxy_classification_code m.0356rr
astronomy.galaxy_classification_code astronomy.galaxy
Galaxy classification code whirlpool
none none
astronomy.galaxy_classification_code.galaxies_of_this_code
Galaxies of this code
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> PREFIX : <http://rdf.freebase.com/ns/> 
SELECT (?x0 AS ?value) WHERE {
SELECT DISTINCT ?x0  WHERE { 
?x0 :type.object.type :astronomy.galaxy_classification_code . 
VALUES ?x1 { :m.0356rr } 
?x0 :astronomy.galaxy_classification_code.galaxies_of_this_code ?x1 . 
FILTER ( ?x0 != ?x1  )
}
}
(AND astronomy.galaxy_classification_code (JOIN astronomy.galaxy_classification_code.galaxies_of_this_code m.0356rr))