babita220004
asked on
display horizontally records
i have only one coloumn in a table i want to dispaly all the datas in a row.Name of the table is student which contains only one coloumns slno
Student
Slno
1
2
3
4
5
I want to display them as
slno 1 2 3 4 5
Student
Slno
1
2
3
4
5
I want to display them as
slno 1 2 3 4 5
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Which server-side language (Script) do you use? Which DB do you use?
If you want to crete a query which will collect values of this one column (Slno) and sore it in one single row, it is only to possible to by creating temporary table with as many columns as you query returns rows. And then, to create (build) a query to insert those values into that temp table.
OR to user pivot table. You could use an OLAP (OnLine Analytical Processing) data cube to get PIVOT functionality. "Pivoting" will be supported in Yukon (next version of ms sql server), and i am not sure about Oracle.
Anyway, to hard task, so If you can skip to do that on sql server - don't do it.