On 14-01-2011 17:55:21 +0100, Stefan Manegold wrote:
IMHO, ORDER BY, LIMIT & OFFSET are useful in SQL. However, they are not part of relational algebra, and hence have so semantical (from a relational algebra pint of view) meaning, but (indeed) purely "cosmetic" (as in result rendering) functionality in SQL. Given that, it does not make much sense for a SQL implementation that (tries to) closely adhere to relational algebra semantics (and the SQL standard) to support ORDER BY, LIMIT & OFFSET in subqueries. Hence, MonetDB support them only in the top-level SQL query block.
... just the way I like to see and phrase this ...
The word useless was very badly chosen from my side. The phrase should most certainly be seen in its context of sub-queries. As far as I can tell the standard dictates that these output functionalities are not allowed within sub-queries.