Filter query terms from hastags and query hastags from terms