Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

dummy column to be displayed

user021Oct 10 2017 — edited Oct 10 2017

I just want to share my scenario with department table, as this is showing right now 3 column as i have only 3 department. However, i want maximum 10 column to be displayed if any department missing

from 1 to 10 deparment then missing department also to be shown.

select *

from table( pivot_fun(' select deptno

                  ,      job

                  from   emp

                ')

        )

        This is current Output

Department.png

Desire Output

dESIRE OUTPU.png

This post has been answered by Lothar Flatz on Oct 10 2017
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 7 2017
Added on Oct 10 2017
4 comments
424 views