I should note this post deals with Views 2.x on Drupal 6.x
When Views doesn't quite spit out the query we are looking for we can turn to
hook_views_query_alter(&$view, &$query) to nudge it in the right direction. This is by no means news, and there are many a blog post detailing various ways to alter the query using this function. However, recently, I ran into an odd issue when attempting to add a
GROUP BY statement.