摘要:
用户表:select count(*) 总表数 from sysobjects where xtype='u' 刚才那个是用户表,下面这个是系统表加用户表:select count(*) 总表数 from sysobject s where xtype in('u','s')总视图数:select ... 阅读全文
摘要:
1 判断数据库是否存在 if exists (select * from sys.databases where name = '数据库名') drop database [数据库名]2 判断表是否存在 if exists (select * from sysobjects where id = ... 阅读全文