Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 Correct the Syntex for : Backup Locally and then C

Author  Topic 

pankajum
Starting Member

2 Posts

Posted - 2011-11-10 : 08:05:39
Sir,

I have Syntax to Backup SQL DataBase Locally and then Copy to the Network Share.

My Local Path is D:\db and Share Path C:\Data and backupfile : dbP.bak
DataBase Name : hospitaA

Please correct the Syntax to use it.

The Syntax :
SET LocalFolder=C:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLBackup
SqlCmd -E -Q “Backup Database MyDB To Disk=’%LocalFolder%MyDB.bak’”
XCopy “%LocalFolder%MyDB.bak” “\192.168.16.55BackupDatabases” /Z /V
DEL “%LocalFolder%MyDB.bak”

Pankaj Kumar
   

- Advertisement -