怎样备份数据库服务器上的数据到本机(客户机器)上?
我的代码如下:不知道客户端的地址应该写什么?
SQLDMO.Backup oBackup = new SQLDMO.BackupClass();
SQLDMO.SQLServer oSQLServer = new SQLDMO.SQLServerClass();
try
{
oSQLServer.LoginSecure = false;
oSQLServer.Connect(server,uid, pwd);
oBackup.Action = SQLDMO.SQLDMO_BACKUP_TYPE.SQLDMOBackup_Database;
oBackup.Database = database;
oBackup.Files = @ "\\客户端的地址怎么写?\d:\dh.bak ";
oBackup.BackupSetName = database;
oBackup.BackupSetDescription = "数据库备份 ";
oBackup.Initialize = true;
oBackup.SQLBackup(oSQLServer);
}
------解决方案--------------------
在客户机做映射+计划任务