Select Rows as Columns..


Posted on 16th Feb 2014 07:03 pm by admin

is there a way to select COLUMN_NAME from user_tab_columns where table_name='TABLENAME';
and have the output as:
COL1, COL2, COL3
instead of:
COL1,
COL2,
COL3

I'd actually like this full statement to be viewed as:
select COLUMN_NAME,DATA_TYPE,DATA_LENGTH,DATA_PRECISION,DATA_SCALE,NULLABLE from user_tab_columns where table_name='EMP';

EMPNO,ENAME,JOB,MGR,HIREDATE,SAL,COMM,DEPTNO
NUMBER,VARCHAR2,VARCHAR2,NUMBER,DATE,NUMBER,NUMBER,NUMBER
22,10,9,22,7,22,22,22
......ect.........

No comments posted yet

Your Answer:

Login to answer
327 Like 34 Dislike
Previous forums Next forums
Other forums

Stopped working!
So I had to change some stuff, none of it major. Stuff like the extension_dir and such. BEFORE I did

asking for direction
I have 2 tables in my data, which are "post" and "event"
I won't make a summa

header redirect problems? please help
Ok i am making a site that generates youtube thumbnails and i am generating an image that displays 1

Function
How can I make this function that once you click the link in the code it takes you to a new page wit

Add trigger to UpdatePanel programmatically
Hi,I'm working on a website which uses AJAX and Masterpages. What I have is an AJAX UpdatePanel whi

GET * FROM _____ Except?
I have a site that is for stock photography.

This section of the code calls images to display

problem getting my contact form working
Yeah I know this is a pretty basic problem, but it's been a while since I've worked with PHP and I'm

Help with echo()
I'm having some problems with this code:

Code: echo '
<A HREF="jav

Firewall / visited websites logger
Hi. I have a firewall implementation and I want to log all the websites visited on the machine. S

Mysql error message
help me find out what this error message means:

"Duplicate entry '0' for key 'PRIMARY'&q

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash