add query filter to queries