22,210
社区成员
发帖
与我相关
我的任务
分享
alter table TB drop column RowGuid
--删除系统表
DECLARE c2 cursor for
select 'drop table ['+name +']; '
from sysobjects
where xtype = 's'
open c2
declare @c2 varchar(8000)
fetch next from c2 into @c2
while(@@fetch_status=0)
begin
exec(@c2)
fetch next from c2 into @c2
end
close c2
deallocate c2
--关键问题是以后你不发布了?
--如果要删除字段,就用。
alter table tablename drop column columnname
--如果要删除表,就用。
drop table tablaname