Re: HASH GROUP BY

From: Jared Still <jkstill_at_gmail.com>
Date: Wed, 23 Apr 2008 13:34:07 -0700
Message-ID: <bf46380804231334l1dbc2d69qc15a1239ac598af6@mail.gmail.com>


On Wed, Apr 23, 2008 at 12:20 PM, Elliott, Patrick < patrick.elliott_at_medtronic.com> wrote:

> Now I understand what you mean by buggy. It no longer sorts the rows.
> If you have code that relies on a group by being in sorted order, then the
> code will no longer work. If you have had to disable this in the past to
> get correct results, then you will need to continue disabling it
> indefinitely. The only way to fix it and reenable the hashing group by is
> to change the code.
>
>

GROUP BY has never been documented to provide rows in sorted order.

From the docs:

The GROUP BY clause groups rows but does not guarantee the order of the
> result set. To order the groupings, use the ORDER BY clause.
>

-- 
Jared Still
Certifiable Oracle DBA and Part Time Perl Evangelist

--
http://www.freelists.org/webpage/oracle-l
Received on Wed Apr 23 2008 - 15:34:07 CDT

Original text of this message