Fixed DISTINCT aggregate functions.