How to attach a SQL Server database file from another server -
i have changed hard disk. databases on old hard disk. have attached old hard disk external hard disk. how can attach database files external hard disk new installed sql server?
you use sql server management studio this:
- in sql server management studio
object explorer
, connect instance of microsoft sql server database engine, , expand instance. - right-click
databases
, clickattach
. - in attach databases dialog box, specify database attached, click
add
; , in locate database files dialog box, select disk drive database resides , expand directory tree find , select.mdf
file of database;
source: https://msdn.microsoft.com/en-us/library/ms190209(v=sql.105).aspx
please note need copy files new server's file system before can attach them. marc_s pointing out.
Comments
Post a Comment