2013年6月2日

SQLserver删除某数据库中所有表

摘要: --删除所有约束DECLARE c1 cursor forselect'alter table ['+ object_name(parent_obj)+'] drop constraint ['+name+']; 'from sysobjectswhere xtype ='F'open c1declare @c1 varchar(8000)fetch next from c1 into @c1while(@@fetch_status=0)beginexec(@c1) fetch next from c1 into @c1endcl 阅读全文

posted @ 2013-06-02 12:19 静以修身俭以养德 阅读(373) 评论(0) 推荐(0) 编辑

导航