Re: SQL Problem. HELP!

From: Claudia Bock <suwelack_at_self.de>
Date: 1997/06/18
Message-ID: <33A83D7B.4504_at_self.de>#1/1


Jerry Glass wrote:
>
> I am lookin for a way to solve a problem. I need to find the highest
> values in a list and only return those values (i.e., find the three
> highest values and only return those three rows)
>
> Jerry Glass

I think your problem could be solved with the following query:

[Quoted] SELECT S0.territory, S0.name, S0.amount
FROM SalesReport S0
WHERE 3 > (SELECT COUNT(*) FROM SalesReport S1

            WHERE S1.territory > S0.territory);

Hope it helps,
Claudia Received on Wed Jun 18 1997 - 00:00:00 CEST

Original text of this message