adding  argument to setQuery method