what monarch is the ruler of a kingdom that is also ruled by princely family of liechtenstein?
Entity Entity Entity Entity Entity Entity Entity Entity Entity Entity
m.01lbgr m.01nyy3 m.03gqg4 m.01hz90 m.01p_4r m.09j48 m.03hpb8c m.08rmj0 m.03h4zjc m.05b4vfd
Wenceslaus II of Bohemia Matthias Corvinus Vladislaus II of Hungary George of Poděbrady Wenceslaus III of Bohemia John of Bohemia Casimir II, Duke of Cieszyn John Corvinus Nicholas I, Duke of Troppau Bolesław III the Generous
class class entity
royalty.monarch royalty.kingdom m.08kx6_
royalty.monarch royalty.kingdom royalty.royal_line
Monarch Kingdom Princely Family of Liechtenstein
none none none
royalty.kingdom.rulers royalty.royal_line.kingdom_s_ruled
Rulers Kingdom(s) ruled
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 :royalty.monarch . 
?x1 :type.object.type :royalty.kingdom . 
VALUES ?x2 { :m.08kx6_ } 
?x1 :royalty.kingdom.rulers ?x0 . 
?x2 :royalty.royal_line.kingdom_s_ruled ?x1 . 
FILTER ( ?x0 != ?x1 && ?x0 != ?x2 && ?x1 != ?x2  )
}
}
(AND royalty.monarch (JOIN (R royalty.kingdom.rulers) (JOIN (R royalty.royal_line.kingdom_s_ruled) m.08kx6_)))