More fixes for map reduce group by support