数据库迁移
备份
BACKUP DATABASE Energy TO DISK = 'c:\databak\data.bak'
RESTORE FILELISTONLY FROM DISK = 'c:\databak\data.bak'
还原数据库
RESTORE DATABASE pro_data
FROM DISK ='c:\databak\data.bak'
WITH MOVE 'Energy' TO 'C:\Program Files\Microsoft SQL Server\MSSQL12.MSSQLSERVER\MSSQL\DATA\pro_data.mdf',
MOVE 'Energy_log' TO 'C:\Program Files\Microsoft SQL Server\MSSQL12.MSSQLSERVER\MSSQL\DATA\pro_data_log.ldf'