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.
| Author |
Topic |
|
rtutus
Aged Yak Warrior
522 Posts |
Posted - 2006-07-19 : 09:24:27
|
| My need: I want to copy my databse (the file itself) in a mem card so that I can use it in another comuter offsite.How do I do that. it s like a back up I think, except that I ll need to import the DB in another computer at home.When I try using Backup the DB of Entreprise Manager, I get violation error, can t copy the file being used or something like that. Am I doing it the right way or is there another better way to do this.Thanks. |
|
|
chiragkhabaria
Master Smack Fu Yak Hacker
1907 Posts |
Posted - 2006-07-19 : 09:29:02
|
| There are 2 options for this.. FirstIf you can detach the database, and take the mdb file it will be good, so that directly you can attach the database.but for these make sure that all the users will be disconnected who are connected to that database. SecondIs to take the backup of the database and then restore at the other computer. It should work fine.Chirag |
 |
|
|
rtutus
Aged Yak Warrior
522 Posts |
Posted - 2006-07-19 : 12:42:29
|
| it worked perfectly. So can t we copy the MDF file without detaching the DB in Entreparise manager.Thanks. |
 |
|
|
Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)
7020 Posts |
Posted - 2006-07-19 : 16:03:46
|
quote: Originally posted by rtutus it worked perfectly. So can t we copy the MDF file without detaching the DB in Entreparise manager.Thanks.
Use backup and restore.CODO ERGO SUM |
 |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2006-07-19 : 16:05:21
|
quote: Originally posted by rtutus it worked perfectly. So can t we copy the MDF file without detaching the DB in Entreparise manager.Thanks.
The only way to guarantee that an attach will work is to detach the database or stop the SQL service prior to the copy of the MDF. I prefer to use BACKUP/RESTORE method as I don't have to take down the database or stop the service. BACKUP/RESTORE allows you to do the move without interrupting the source.Tara Kizer |
 |
|
|
rtutus
Aged Yak Warrior
522 Posts |
Posted - 2006-07-20 : 08:20:12
|
| thank you |
 |
|
|
|
|
|