BCM 2003 attach error message

In order to fix a broken installation of Business Contact Manager 2003, running on XP, I had to copy the MDF and LDF files to another location on the same machine and reinstall BCM. I also installed SQL Studio 2005. When I tried to attach the data to the new database, I get the error msg "Cannot  Attach to a database with the same name". I tried renaming the MDF and LDF files by adding a 1 to the names. That didn't work. I then tried renaming the instance of the Database in Studio and that didn't work. So what can I do to get around this issue? Thanks any and all help.
PCGenieLAAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

lcohanDatabase AnalystCommented:
<<When I tried to attach the data to the new database, I get the error msg "Cannot  Attach to a database with the same name". >>

Assuming you have the MDF/LDF files still renamed please try following:
in SSMS innitiate the "Attach Database" and point to the [..]1.MDF file and when it reads the header and populate the field with that database name you can change it - typeover or add a suffix/prefix - whatever works for you and then either script it and run the script or just hit the OK.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
PCGenieLAAuthor Commented:
I found the following script online and was able attach the Db using it. I think it's essentially the same thing as yours:
"c:\program files\microsoft sql server\90\tools\binn\sqlcmd.exe" -b -E -S .\MSSMLBIZ -Q "EXEC sp_attach_db @dbname = 'Master1', @filename1 = '%LOCALAPPDATA%\Microsoft\Business Contact Manager\Master1.mdf', @filename2 = '%LOCALAPPDATA%\Microsoft\Business Contact Manager\Master1.ldf';">>"%LOCALAPPDATA%\Microsoft\Business Contact Manager\Master1_RestoreResult.txt"
@ECHO Attach DB Returned:%ERRORLEVEL%>>"%LOCALAPPDATA%\Microsoft\Business Contact Manager\Master1_RestoreResult.txt"
@ECHO Attach DB Returned:%ERRORLEVEL%
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Databases

From novice to tech pro — start learning today.