how can we write a column values horizontal by using sql stmt;
ex:
select name from table_name;(actual output)
a
b
c
d
require output is
a b c d

Answer Posted / ajit

select Replace ( Wm_concat( a ), ',' ) Actout
from Tablename;

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a pragma statement?

723


Can we create view in stored procedure?

526


What is before trigger?

558


Explain the difference between drop and truncate commands in sql?

538


How can you get sql*loader to commit only at the end of the load file? : aql loader

556






What is sql keyword?

568


how to decrement dates by 1 in mysql? : Sql dba

584


How to display the current date in sql?

603


What is the use of <> sql?

556


Determine if oracle date is on a weekend?

558


What are the three forms of normalization?

537


What is the difference between execution of triggers and stored procedures?

556


What are sql objects?

546


What is the starting oracle error number?

569


what is commit? : Sql dba

619