Subject Re: [firebird-support] List function, how to sort (FB 2.1)
Author Dmitry Yemanov
rj1102 wrote:
>
> But how do I sort the values within the list result?

Generally, you cannot. The current implementation doesn't support any
explicit ordering.

However, you could try something like this:

SELECT MyField1+0, List(MyField2)
FROM (SELECT MyField1, MyField2 FROM MyTable ORDER BY MyField1,
MyField2)
GROUP BY MyField1+0

(if MyField1 is a string, replace +0 with ||'')

It should provide the ordered list.


Dmitry