SELECT * FROM tempdb..syscolumns
WHERE (id = OBJECT_ID('tempdb..#temp'))
得到正常表列数
SELECT * FROM syscolumns
WHERE (id = OBJECT_ID('tablename'))
SELECT * FROM tempdb..syscolumns
WHERE (id = OBJECT_ID('tempdb..#temp'))
得到正常表列数
SELECT * FROM syscolumns
WHERE (id = OBJECT_ID('tablename'))