1、备份
sql = backup database ICMG to disk = 'F:/ICMG.bak'
2、还原
sql1 = Use Master Alter Database ICMG SET SINGLE_USER With ROLLBACK IMMEDIATE
sql2 = restore database ICMG from disk = 'F:/ICMG.bak'
sql3 = Use master Alter Database ICMG SET MULTI_USER
以上sql语句依次运行,在还原时要断开之前的数据库连接,然后用master登陆