Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.tools -> Re: sql aggregate question

Re: sql aggregate question

From: Myron Wintonyk <mwintony_at_med.ualberta.ca>
Date: Thu, 18 Jan 2001 12:30:21 +1000
Message-ID: <3A66553D.A61A2@med.ualberta.ca>

Sorry, asleep at the wheel!

REMOVE the A.PLAYER = B.PLAYER altogether ... Sorry again ...

select team, name, score from players A

       where score = ( select max( score)
                                from players B
                                where A.TEAM = B.TEAM );

Doug Edmunds wrote:

> Myron Wintonyk <mwintony_at_med.ualberta.ca> wrote in
> <3A663A39.F777BDCC_at_med.ualberta.ca>:
>
> >select team, name, score from players A
> > where score = ( select max( score)
> > from players B
> > where A.PLAYER = B.PLAYER
> > and A.TEAM = B.TEAM );
> >
> Even after I changed your line
> where A.PLAYER = B.PLAYER
> to
> where A.NAME = B.NAME (there's no field named player)
> it still doesn't work for me.
> That sql produces a list of all the names,
> not just the top scorers.
>
> -- doug edmunds
> 17 Jan 2001
Received on Wed Jan 17 2001 - 20:30:21 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US