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

Home -> Community -> Usenet -> c.d.o.server -> Re: Group By question

Re: Group By question

From: Sybrand Bakker <gooiditweg_at_sybrandb.verwijderdit.demon.nl>
Date: Tue, 17 Aug 2004 00:11:27 +0200
Message-ID: <l6c2i0d4o0b7dbupr0j2s4d24lsrnph391@4ax.com>


On 16 Aug 2004 13:58:17 -0700, dennishancy_at_eaton.com (Dennis Hancy) wrote:

>I have a table with this structure:
>
>SSN varchar2
>NAME varchar2
>DEPT number
>
>
>I need to produce a report that looks like this:
>
>Dept Name
>0001 Edmund
> Miranda
> Zachary
>0002 Stuart
> Mary
> Erica
> Kendall
> Adam
> Jamie
>0003 Maria
> Ryan
>
>In other words, I don't want to repeat the the department number. I
>only want to see it on the first line.
>
>How do I accomplish this with SQL?
>
>Thanks.
>
>
>Dennis Hancy
>Eaton Corporation
>Cleveland, OH

in sql*plus
break on dept nodup

--
Sybrand Bakker, Senior Oracle DBA
Received on Mon Aug 16 2004 - 17:11:27 CDT

Original text of this message

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