Subject Re: [firebird-support] GROUP BY odd results - can someone explain please?
Author Mark Rotteveel
On 19-6-2014 16:58, tomconlon7@... [firebird-support] wrote:
> I was expecting to see one row for
>
> "melvin comms directors 30.04.13" and also for "DCFTG210513".
>
> QUERY
>
> select '['|| TRIM(SUBSTRING(COMMENTS FROM 1 FOR 100)) || ']', count(*)
> from target
> group by 1
> having count(*)>5
> order by 1
>
> RESULTS
>
> [null]2289
> [melvin comms directors 30.04.13]17
> [melvin comms directors 30.04.13]52
> [melvin comms directors 30.04.13]18
> [melvin comms directors 30.04.13]8
> [melvin comms directors 30.04.13]6
> [DCFTG210513]14
> [Rackable/SGI]10
> [microsoft james 15.03]15
> [microsoft james 15.03]8
> [NWSEI060613]6
> [DCFTG210513]19
> [DCFTG210513]19
> [lifesiences]7
> [DCFTG210513]37
> [DCFTG210513]17
> ....

Your expectation is right (if this is the actual data, and there is no
difference in - for example - whitespace).

I'd suggest you try with the latest Firebird version (you didn't mention
a version), and file a bug with a database and a script that allows this
problem to be reproduced. Don't forget to include the Firebird version
in the bug report.

Mark
--
Mark Rotteveel