Link to home
Start Free TrialLog in
Avatar of Balshe
Balshe

asked on

Column to Rows

Dears,

i have a table with one column, i want to a query to show this column as rows and columns as below:

      Column1 | Column2|Column3|Column4
Row1      AA               AB          AC          AD
Row2      AE               AF          AG         AH
Row3      AI                BA          BB         BC
Row4 .............................



to make it easier here is the table:

create table TST
(
  X VARCHAR2(10)
);

Values:


insert into tst(x) values ('AA');
insert into tst(x) values ('AB');
insert into tst(x) values ('AC');
insert into tst(x) values ('AD');
insert into tst(x) values ('AE');
insert into tst(x) values ('AF');
insert into tst(x) values ('AG');
insert into tst(x) values ('AH');
insert into tst(x) values ('AI');
insert into tst(x) values ('BA');
insert into tst(x) values ('BB');
insert into tst(x) values ('BC');




thanks all
ASKER CERTIFIED SOLUTION
Avatar of Sean Stuber
Sean Stuber

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Balshe
Balshe

ASKER

Thanks a lot man