-- disable all constraints EXEC sp_msforeachtable "ALTER TABLE ? NOCHECK CONSTRAINT all" -- delete data in all tables EXEC sp_MSForEachTable "DELETE FROM ?" -- enable all constraints exec sp_msforeachtable "ALTER TABLE ? WITH CHECK CHECK CONSTRAINT all"
What's up!
Pyaarey Allah!
Sunday, March 27, 2011
Truncate db
Subscribe to:
Post Comments (Atom)
0 comments: (+add yours?)
Post a Comment