Hello all.
I run a bunch of DBCC tasks this weekend using sp_MSforeach... and it work great. I have a quick question, though. Can I execute a store proc within any of those?
I have quite a few stored procs for maintenance and they run quite well, but of course I have to call each one everytime (well, not me personally!! a DTS) is any way I can incorporate sp_MSforeach... to run this stored procs? or any other command?
something like:
exec sp_MSforeachtable @command1 ="print '?' TRUNCATE TABLE ('?')"
or
exec sp_MSforeachtable @command1 ="print '?' exec usp_updateZipCode ('?')"
Thank you