Software Development and stuff

Discussions relating to Software Development. Other rants thrown in for free

Tuesday, October 28, 2008

20 Second SQL tip

If you restore from a backup with NORECOVERY from the GUI it sometimes doesn't bring the database back online, even if the restore succeeds.

So if you are stuck with a database that no matter how long you give it, the status is restoring, or loading the following command should work:

RESTORE DATABASE databaseName WITH RECOVERY
Posted by KiwiBastard at 2:53 pm

No comments:

Post a Comment

Newer Post Older Post Home
Subscribe to: Post Comments (Atom)

Blog Archive

  • ►  2022 (3)
    • ►  October (3)
  • ►  2015 (4)
    • ►  February (4)
  • ►  2013 (1)
    • ►  May (1)
  • ►  2010 (1)
    • ►  February (1)
  • ►  2009 (3)
    • ►  January (3)
  • ▼  2008 (84)
    • ►  December (2)
    • ▼  October (5)
      • Linking iPhone/iPod Touch with Xcode
      • 20 Second SQL tip
      • StackOverflow: the good, the bad, the ugly
      • Nice Gmail Tip: plus-addressing
      • Useful Vista Tip: Open Command Window
    • ►  September (2)
    • ►  August (8)
    • ►  July (15)
    • ►  June (4)
    • ►  May (7)
    • ►  April (13)
    • ►  March (7)
    • ►  February (3)
    • ►  January (18)
  • ►  2007 (51)
    • ►  December (8)
    • ►  November (3)
    • ►  September (1)
    • ►  August (5)
    • ►  July (4)
    • ►  June (5)
    • ►  May (5)
    • ►  April (2)
    • ►  February (9)
    • ►  January (9)
  • ►  2006 (96)
    • ►  December (7)
    • ►  November (14)
    • ►  October (10)
    • ►  September (18)
    • ►  August (10)
    • ►  July (5)
    • ►  June (3)
    • ►  May (9)
    • ►  April (5)
    • ►  March (7)
    • ►  February (6)
    • ►  January (2)

Links

  • SoftwareX
  • Nic Wise Blog

Stat Counter

Statcounter View My Stats

Contributors

  • KiwiBastard
  • Roger H
  • Shaun Austin

C-List Blogger
Theme images by fpm. Powered by Blogger.