how to find number of columns in a table in sql server 2000
and 2005 also
Answer Posted / vidit tyagi
SELECT Count(*)As Coloumns
FROM SysColumns
Where ID =
(SELECT ID FROM SysObjects Where Name = 'TableName')
| Is This Answer Correct ? | 6 Yes | 4 No |
Post New Answer View All Answers
How to convert numeric expression data types using the cast() function?
Write SQL queries on Self Join and Inner Join.
What are the properties of the relational tables?
What are trace flags and mention a few common trace flags used with sql server?
Can a rule be bound to any column of any data type?
How to delete multiple rows with one delete statement in ms sql server?
What are the basic functions for master, msdb, model, tempdb and resource databases? : SQL Server Architecture
How to connect to a sql server using odbc_connect()?
How will you make an attribute not process? : sql server analysis services, ssas
What part does database design plays a role in performance of an sql server-based application?
What is difference between delete and truncate commands?
Explain nested trigger in sql?
What is encryption key?
What is the difference between index seek vs. Index scan?
What are types of storage modes? : sql server analysis services, ssas