Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: sql query formatting
Madis Priilinn <madp_at_math.ut.ee> wrote in message news:<Pine.GSO.4.33.0108141634540.29500-100000_at_madli.ut.ee>...
> Hello!
>
> I would like to format one query. Right now it shows something like this
> example (grouped by first column):
>
>
> DNAME JOB Total Empl Average Sa
> --------------- --------- ---------- ----------
> ACCOUNTING CLERK 1 15600
> ACCOUNTING MANAGER 1 29400
> ACCOUNTING PRESIDENT 1 60000
> ACCOUNTING All Jobs 3 35000
> RESEARCH ANALYST 2 36000
> RESEARCH CLERK 2 11400
> RESEARCH MANAGER 1 35700
> RESEARCH All Jobs 5 26100
>
> But my intention is to get something like this:
>
> DNAME JOB Total Empl Average Sa
> --------------- --------- ---------- ----------
> ACCOUNTING CLERK 1 15600
> MANAGER 1 29400
> PRESIDENT 1 60000
> All Jobs 3 35000
> RESEARCH ANALYST 2 36000
> CLERK 2 11400
> MANAGER 1 35700
> All Jobs 5 26100
>
>
> I've searched several hours already but can't find anything...But I don't
> want to believe this is impossible to do :)
>
> Thank You,
>
> Madis
Madis, look up the SQLPLUS break command
break on dname nodup
![]() |
![]() |