Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Backup Problem

Status
Not open for further replies.

NormRumac

Programmer
Sep 4, 2003
41
CA
Several months ago I foolishly named my SQL (actually MSDE) database "my-database". Over the last few months several applications which reference the database with this name have been created.

Now that the database has recently gone from "test" mode, to "production" mode, I want to start doing automatic scheduled backups. I created a script to be processed my the Osql.exe utility. This script consists of one line:

BACKUP DATABASE my-db to disk = 'c:\temp\db.bak'

As it turns out, osql.exe will barf on the '-' part of 'my-db'.

I can obviously get around this problem by renaming the database, but then all those existing client applications which reference this database are going to break.

So what can i do now?

 
Try ...

BACKUP DATABASE [my-db] to disk = 'c:\temp\db.bak'

Thanks

J. Kusch
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top