Fix Export when full group by mode is used
After upgrading locally to mysql 5.7 I found that the exportIM test
was taking so long locally that I was killing it rather than finding
out how long it would take.
Digging into it I found that we were changing the query so that
attempts to group by contact ID were being nullified when full group by
is enabled. This meant that we were winding up with
7776 rows being retrieved to reflect a grid of permutations, which was
being iterated down to 1 in php.
In general the practice of altering the groupby to meet this new
standard is one that we determined to be
causing problems and we discontinued / rolled back