> This should work: > > SELECT ?x { > ?x a ex:A . > OPTIONAL { > ?x a ?type . > FILTER(?type != ex:A) > } > FILTER(!bound(?type)) > } > > The OPTIONAL here tries to find a different type for the same resource > (?x). If it succeeds then ?type is bound to a second class, so we filter > out that case at the top-level. And it does. I just ran it twinkle and it produces the expected single result. Nice work. I spent a long time scratching my head with that one. Didn't occur to me to split the FILTERs into the separate OPTIONAL patterns. Fun! L.Received on Friday, 1 February 2008 20:39:41 GMT
This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 1 February 2008 20:39:41 GMT