1BY LOVE
2
3EXEC sp_msforeachtable "ALTER TABLE ? NOCHECK CONSTRAINT all"
4DECLARE @sql NVARCHAR(max)=''
5
6SELECT @sql += ' Drop table ' + QUOTENAME(TABLE_SCHEMA) + '.'+ QUOTENAME(TABLE_NAME) + '; '
7FROM INFORMATION_SCHEMA.TABLES
8WHERE TABLE_TYPE = 'BASE TABLE'
9Exec Sp_executesql @sql
10