implements a few more method calls; fixes the query method to actually use supplied arguments