allow aggregate functions in sort specification