I've executed the following script to delete/truncate all tables within a specific DB :
EXEC sp_MSForEachTable 'DISABLE TRIGGER ALL ON ?'
GO
EXEC sp_MSForEachTable 'ALTER TABLE ? NOCHECK CONSTRAINT ALL'
GO
EXEC sp_MSForEachTable 'DELETE FROM ?'
GO
EXEC sp_MSForEachTable 'ALTER TABLE ? CHECK CONSTRAINT ALL'
GO
EXEC sp_MSForEachTable 'ENABLE TRIGGER ALL ON ?'
GO
Would the script above truncate all tables in all DBs or just the DB I'm running it in?
it will execute only in DB you are running it in. However for safety use USE yourDBName at the top of the query window
Try like this ,