Fix bug#12887 Distinct is not always applied after rollup
For queries with GROUP BY and without hidden GROUP BY fields DISTINCT is optimized away becuase such queries produce result set without duplicates. But ROLLUP can add rows which may be same to some rows and this fact was ignored. Added check so if ROLLUP is present DISTINCT can't be optimized away.
Showing
Please register or sign in to comment