Re: Many aggregates in one query

From: Mikito Harakiri <mikharakiri_at_yahoo.com>
Date: 17 Aug 2001 10:10:02 -0700
Message-ID: <bdf69bdf.0108170910.60c955c1_at_posting.google.com>


Heinz Huber <hhuber_at_racon-linz.at> wrote in message news:<3B7D0AA9.4F9298C4_at_racon-linz.at>...  

> If you're using ASA 7 (and perhaps also 6), you can use the following query:
> SELECT MIN(wsid), MIN(rowcnt)
> FROM (SELECT wsid, COUNT(wsid) AS rowcnt
> FROM test
> GROUP BY wsid
> HAVING COUNT(wsid) = MIN(COUNT(wsid)) t;
>
> Perhaps it works for other DMBSs, too.
 

Not with Oracle:

ORA-00935 group function is nested too deeply Cause: This is an internal error message not usually issued. Action: Contact Oracle Customer Support Received on Fri Aug 17 2001 - 19:10:02 CEST

Original text of this message