“We are committed to delivering the exact services our commercial cleaning customers want, listening closely to their expectations, taking a pro-active approach in defining their needs, and building the best partnering relationship possible. We are also committed to acting with honesty and integrity at all times in all aspects of our business, to being professional in doing our job, and to delivering a consistent, high level quality of work.”
Page 1 Delete all the rows from all the tables in SQL Server If you are in situation where you just want empty database structure, without having data in it. Run following select statement which will generate set of delete statement to delete all the records for all the tables in your database. SELECT 'Delete from ' + Table_Catalog + '.' + Table_Schema + '.' + Table_Name + ';' FROM INFORMATION_SCHEMA.TABLES WHERE Table_Type = 'BASE TABLE' ORDER by TABLE_NAME In case your database is large and you want to know status of which table is currently getting deleted you can use following: SELECT 'Print(''Delete started for ' + Table_Catalog + '.' + Table_Schema + '.' + Table_Name + ''');' + 'Delete from ' + Table_Catalog + '.' + Table_Schema + '.' + Table_Name + ';' + 'Print(''Delete done for ' + Table_Catalog + '.' + Table...
Comments
Post a Comment