| Author: sathiyasivam 31 Aug 2007 | Member Level: Diamond | Rating:  Points: 2 |
Hi ,
In the system table you can find this yar. Please check the systable. I think it is syscolumn.
Regards sathiya
|
| Author: Shivshanker Cheral 01 Sep 2007 | Member Level: Diamond | Rating:  Points: 2 |
Select TABLE_CATALOG , TABLE_SCHEMA, TABLE_NAME , COLUMN_NAME From stars_db.Information_Schema.Columns Where Table_Name like 'Table_Name'
|
| Author: Shivshanker Cheral 01 Sep 2007 | Member Level: Diamond | Rating:  Points: 2 |
to count use this Select count(COLUMN_NAME) From stars_db.Information_Schema.Columns Where Table_Name like 'Table_name'
stars_db is database name and Table_name is table name which you want to count number of columns
|
| Author: Padma 03 Sep 2007 | Member Level: Diamond | Rating:  Points: 2 |
hi check this
SELECT count(*)
FROM INFORMATION_SCHEMA.columns
WHERE table_name='tabTest'
|
| Author: Padma 03 Sep 2007 | Member Level: Diamond | Rating:  Points: 2 |
hi check this
SELECT count(*)
FROM INFORMATION_SCHEMA.columns
WHERE table_name='tabTest'
|
| Author: SUJITH 26 Sep 2007 | Member Level: Silver | Rating:  Points: 2 |
Hi Try this
select count(sc.name) from syscolumns sc,sysobjects so where sc.id=so.id and so.name ='tablename'
|