count [message #35948] |
Thu, 25 October 2001 07:08 |
neru
Messages: 2 Registered: October 2001
|
Junior Member |
|
|
Hi,
Is there any way to make count of the number of columns
in a table.
ex: table A has 100 columns
Thanks
----------------------------------------------------------------------
|
|
|
Re: count [message #35953 is a reply to message #35948] |
Thu, 25 October 2001 08:52 |
Jon
Messages: 483 Registered: May 2001
|
Senior Member |
|
|
select table_name, count(column_name) from all_tab_columns
where owner = 'xxx'
/* and table_name = tableA */
group by table_name
----------------------------------------------------------------------
|
|
|
Re: count [message #35983 is a reply to message #35948] |
Sun, 28 October 2001 20:30 |
akkiraju kiran kumar
Messages: 6 Registered: October 2001
|
Junior Member |
|
|
hai,
To find how many columns in a specific table.
To get this first decide in which schema the
table is exist.
For Example i am considering SCOTT schema having the table EMP.
so to find out the columns in this criteria
select count(*) from all_Tab_columns
where table_name='EMP' and owner='SCOTT'
bye
best of luck
----------------------------------------------------------------------
|
|
|