Eng 6553 group by alias

Waiting for Jenkins...
I can remove this include now after I discard the usage of hsql's hashset.