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

Home -> Community -> Usenet -> c.d.o.misc -> Re: An SQL question

Re: An SQL question

From: Corinna Becker <Corinna.Becker_at_memo.ikea.com>
Date: 11 Aug 1998 09:30:34 GMT
Message-ID: <01bdc50a$af602320$a049100a@pc743-sode.seurope.ikea.com>


Hello Chris,
try the following:
select max(Bal_Period)
from your_table
group by EmpIID,

              Year;
Regards
Corinna

Chris Daugherty <quasar_at_flash.net> wrote in article <35CF6ED9.4CA4_at_flash.net>...
> Greetings! I need write SQL to do the following:
> I have a table that has these columns:
>
> EmplID Year Bal_ID Bal_Period
> -----------------------------------------
> 8158 1997 CY 1
> 8158 1997 CY 2
> 8158 1997 CY 3
> 8158 1997 CY 4
> 8158 1998 CY 1
> 8158 1998 CY 2
> 8158 1998 CY 3
> 8158 1998 CY 4
> 8158 1998 CY 5
> 8111 1997 CY 1
> 8111 1997 CY 2
> 8133 1997 CY 1
> 8133 1997 CY 3
>
> I need to pull the maxium Bal_Period for each Year for each EmplID. How
> do I do that?
>
> Please respond as well as post the answer to cmdaugherty_at_pier1.com
>
> Thanks!
>
> CMD
>
Received on Tue Aug 11 1998 - 04:30:34 CDT

Original text of this message

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