What is {headquarters location} of {State University of New York} that is {postal code} is {12246} ?
What campus of SUNY is in the 12246 zip code?
Which campus of the State University of New York has the zip code 12246?
SELECT ?o WHERE { ?q property:headquarters_location ?o . resource:State_University_of_New_York property:headquarters_location ?q . FILTER ( ?v = 12246 ) . ?q property:postal_code ?v }
select distinct ?obj  where {
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q1140241> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P159> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> ?obj .
?statement <http://www.wikidata.org/entity/P281> <12246>
} 

SELECT ?obj WHERE { wd:Q1140241 p:P159 ?s . ?s ps:P159 ?obj . ?s pq:P281 ?x filter(contains(?x , '12246')) }