sqlserver 刪除數據庫的全部表

use Table --數據庫名(是要刪除表的所在的那個數據庫的名稱)sql GO declare @sql varchar(8000) while (select count(*) from sysobjects where type='U')>0 begin SELECT @sql='drop table ' + name FROM sysobjects WHERE (type = 'U')
相關文章
相關標籤/搜索