数据库
首页 > 数据库> > sqlserver 删除表 视图 函数 存储过程

sqlserver 删除表 视图 函数 存储过程

作者:互联网

use tax_ceshi
select 'DROP TABLE '+name from sysobjects where type = 'U'
union
select 'DROP VIEW '+name from sysobjects where type = 'V'
union
select 'DROP PROC '+name from sysobjects where type = 'P'
union
select 'drop function '+name from sysobjects where type = 'tf'
union
select 'drop function '+name from sysobjects where type = 'fn'

标签:存储,name,unionselect,where,DROP,sqlserver,视图,type,sysobjects
来源: https://www.cnblogs.com/zhang-wenbin/p/10404739.html