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 |
|
vasu4us
Posting Yak Master
102 Posts |
Posted - 2006-11-15 : 11:46:35
|
| I am trying to use sp_attach_db SP.I have a dadafile and a log file at D:\Asset which I am trying to extract usingEXECUTE sp_attach_db 'Asset', 'D:\Asset\Asset_data.mdf','D:\Asset\asset_log.ldf'can any one of u tell where i went wrongI am getting this errror "Device activation error. The physical file name 'D:\Asset\aa\Asset_data.mdf' may be incorrect."I am trying to use the database provided fromhttp://www.trigonblue.com/sp_download.htm#Diagram to practise stored procedures.Thanks in advance |
|
|
snSQL
Master Smack Fu Yak Hacker
1837 Posts |
Posted - 2006-11-15 : 11:54:12
|
| The error says you are using the path D:\Asset\aa but you gave the path as D:\Asset in the command you're trying to use.If you use the command you say you are, and the files are in the D:\Asset folder then it will work fine. |
 |
|
|
vasu4us
Posting Yak Master
102 Posts |
Posted - 2006-11-15 : 13:08:44
|
| I have the files at 'D:\Asset\Asset_data.mdf', 'D:\Asset\asset_log.ldf'I connect to a remote SQL server using Query Analyzer which opens a window with master DB connectionand when i run this comand EXECUTE sp_attach_db 'Asset', 'D:\Asset\Asset_data.mdf','D:\Asset\asset_log.ldf'I am getting the same errorDevice activation error. The physical file name 'D:\Asset\Asset_data.mdf' may be incorrect. |
 |
|
|
snSQL
Master Smack Fu Yak Hacker
1837 Posts |
Posted - 2006-11-15 : 13:44:04
|
| OK, in that case are your files on the D: drive of your computer or the server? They must be on the server's D: drive. |
 |
|
|
vasu4us
Posting Yak Master
102 Posts |
Posted - 2006-11-15 : 14:34:59
|
| you were right on dot i copyed the files to server and then it worked. thank you |
 |
|
|
|
|
|