You have one database on your production server. You detached and copied it
to development server and modified it. Now, you are moving the modified
database to your production. You do not want to touch your production
database and leave it running. The question that lingers in my mind is, what
are you going to do with that modified database if you are not going to
touch the production database.
I know, it's not my business. I just wonder...
Regarding to the following error. You said that you have another copy of
your production database which is the "modified" one. So why do not you
change it's file name, file location and attach it as a different name. Of
course it would not let you to attach it if you point to the same location
as your production database's (if this is your situation.) However, I do not
see any reason to prevent you to attach a database which has a different
phsycal name, logical name and location. You can change it all.
--
Ekrem Önsoy
"Kevin F (Michigan)" <KevinFMichigan@discussions.microsoft.com> wrote in
message news:D12A0A29-B683-48EC-8F00-A52F250BA1DC@microsoft.com...
[quoted text, click to view] > Thanks for your reply, but I don't think that will work, as it still
> points
> to the original file names/locations in the "attach" dialog. I gave it
> shot
> on my local instance (renaming a db file and attaching it under a
> differnet
> db name) and I got the following error:
>
> Error 5105: The physical file name "C......" may be incorrect.
>
> In the error the physical file name pointed to the OLD mdf file, NOT the
> new, renamed file. This is what I thought might happen....any other
> suggestions are welcome.
>
>
> "Ekrem Önsoy" wrote:
>
>> Using EM, go to Attach Database and find your modifed mdf file and open
>> it.
>> You' ll see a textbox which is labeled as "Attach as:" You can change
>> your
>> modified database's name before completing the Attach Database process
>> using
>> that way.
>>
>> --
>> Ekrem Önsoy
>>
>>
>>
>> "Kevin F (Michigan)" <KevinFMichigan@discussions.microsoft.com> wrote in
>> message news:00D2B564-D042-441C-B5D2-B8B9D2F252A2@microsoft.com...
>> >I detached a production db, copied to my test environment (desktop),
>> >modified
>> > it, and now wish to copy it back to the production server WITHOUT
>> > overwriting
>> > the exiting copy on the production server. Both dbs have the same
>> > name,
>> > and
>> > I DO NOT want to overwrite the production db. I renamed the files and
>> > tried
>> > to attach them, but the "original files" option seemed to point to the
>> > existing production db. How can I do this? Backup/Restore? I'm
>> > DEATHLY
>> > afraid of losing the production db (and thus, my job : ) so I don't
>> > have
>> > any
>> > room for my usual steps of "try this, try that, try something else"
>> > until
>> > I
>> > figure it out. Any help is appreciated - thanks!
>>