sqlServer
select count(*) from sys.columns a,sys.tables b
where a.object_id = b.object_id and b.name = '表名';
Oracle
select
count
(*)
from
user_tab_cols
where
table_name=
'表名'
;
--表名含自英文的话应百为英文大写字母
mysql
select
count
(*)
from
information_schema.COLUMNS
where
table_name=
'表名'
;
--表名大小写均可答