sql中如何获得数据表的字段数?

select count(name) from syscolumns where id=object_id('表名')

http://blog.csdn.net/LatestEntry.aspx?CategoryID=47
 

你可能感兴趣的:(sql中如何获得数据表的字段数?)