Subject Re: [firebird-support] Unions
Author Arno Brinkman
> Is it somehow possible to order the the product of a union ?
>
> SELECT .... blah blah blah
>
> UNION
>
> SELECT .... blah blah blah
>
> ORDER BY Item1

use ORDER BY <position>

for example :

SELECT
Field1,
Field2
FROM
TableA
UNION ALL
SELECT
Field1,
Field2
FROM
TableB
ORDER BY
2

will sort on the 2nd field

Regards,
Arno Brinkman
ABVisie

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Firebird open source database (based on IB-OE) with many SQL-99 features :
http://www.firebirdsql.org
http://www.firebirdsql.info
http://www.fingerbird.de/
http://www.comunidade-firebird.org/

Support list for Interbase and Firebird users :
firebird-support@yahoogroups.com

Nederlandse firebird nieuwsgroep :
news://80.126.130.81