the ship class who has paul wright as a designed is what ship type?
Entity
m.062z98q
Sailing Dinghy
class class entity
boats.ship_type boats.ship_class m.062zg59
boats.ship_type boats.ship_class boats.ship_designer
Ship type Ship class Paul Wright
none none none
boats.ship_class.ship_type boats.ship_class.designer
Ship type (ex: oil tanker, destroyer) Designer
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 :boats.ship_type . 
?x1 :type.object.type :boats.ship_class . 
VALUES ?x2 { :m.062zg59 } 
?x1 :boats.ship_class.ship_type ?x0 . 
?x1 :boats.ship_class.designer ?x2 . 
FILTER ( ?x0 != ?x1 && ?x0 != ?x2 && ?x1 != ?x2  )
}
}
(AND boats.ship_type (JOIN (R boats.ship_class.ship_type) (JOIN boats.ship_class.designer m.062zg59)))