sp_MSforeachtable sproc

October 30th, 2007 by Xerx Leave a reply »

LINK: http://weblogs.sqlteam.com/joew/archive/2007/10/23/60383.aspx

Why write a cursor to traverse each table this stored proc allows you to traverse each table automatically:

EXECUTE sp_MSforeachtable ‘EXECUTE sp_spaceused [?];’;

Neat!

——————

Bookmark this post:
  • DotNetKicks
  • DZone
  • TwitThis
  • Digg
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • LinkedIn
  • Live
  • MySpace
  • Slashdot
  • StumbleUpon
  • Technorati

Related posts:

  1. Rhino vs Moq All i can start with at this stage is wow….....
  2. Instant Twitter Bookmark Tonight’s been a busy night for silly coding This first...
  3. Struct Constructor Initialisation I’m working on a personal project atm (more details to...
  4. NUnit 2.5 Beta now supported in TestDriven.NET http://weblogs.asp.net/nunitaddin/archive/2008/12/02/testdriven-net-2-18-nunit-2-5-beta.aspx Jamie covers off some of the new things in...
  5. Finding out what’s process is listening on port 80 Just saw an excellent tweet by @chadmyers: FYI, to find...

Leave a Reply