sorting tags in the query filter