Mysql 5.1 union with group by for results

2013-11-08 Thread Machiel Richards
Good day all I am hoping someone can assist me in the following. One of our servers were running mysql 5.0 still and as part of a phased upgrade route we have upgraded to version 5.1. However since the upgrade, the query below gives us an error stating that the syntax

Re: Mysql 5.1 union with group by for results

2013-11-08 Thread Jesper Wisborg Krogh
Hi Machiel, On 8/11/2013 20:04, Machiel Richards wrote: Good day all I am hoping someone can assist me in the following. One of our servers were running mysql 5.0 still and as part of a phased upgrade route we have upgraded to version 5.1. However since the upgrade,

Re: Mysql 5.1 union with group by for results

2013-11-08 Thread Johan De Meersman
- Original Message - From: Machiel Richards machiel.richa...@gmail.com ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'GROUP BY t.AccountID, I suspect your query has never

Re: Mysql 5.1 union with group by for results

2013-11-08 Thread Machiel Richards
Happiness, that gave me what I was looking for. Thank you Johan. I have tested the option you gave me but my brackets was in the wrong place. On 08/11/2013 13:23, Johan De Meersman wrote: - Original Message - From: Machiel Richards machiel.richa...@gmail.com ERROR 1064 (42000):

Re: Mysql 5.1 union with group by for results

2013-11-08 Thread Machiel Richards
Hi Jesper I was just discussing this with the development manager now and the following was noted. - The query was written for mysql 4.0 originally and it seems that in version 5.0 they had enabled some legacy support stuff ( I am not too familiar with this as it is before my