more concise .sort() for queries