GROUP BY comes before ORDER BY

This generated an error in queries
Merge pull request #35 from MikeVelazcoMtz/patch-2

GROUP BY comes before ORDER BY