Hi,
I'm trying to restore a backup file to a data base on a different server by
overwriting it.
In order to do this I need to move the logical file I am restoring to the
location of the physical database file I am restoring to (as per the prompt I
am receiving)
When it say "MOVE", will this in fact move the file over & possibly damage
the database from which the restore is being taken? Does it move any files or
just copy?
Is there any danger here?
Below is what I'm doing:
RESTORE DATABASE oneDB
FROM DISK = 'C:\myPhysicalBackupFile'
WITH REPLACE,
MOVE 'myLogicalFile' TO 'C:\Program Files\Microsoft SQL
Server\MSSQL\data\PhysicalFile.MDF'
Many thanks for any help on this
AntIt's a little confusing the first time, but all the MOVE is doing is telling
the engine where to place the MDF file. The FROM is the .BAK file.
And if you're overwriting an exiting database, then yes, you're gonna whack
it. But that is expected behavior.
"Ant" <Ant@.discussions.microsoft.com> wrote in message
news:69B97720-9594-48A8-9181-53F874B8EB3E@.microsoft.com...
> Hi,
> I'm trying to restore a backup file to a data base on a different server
> by
> overwriting it.
> In order to do this I need to move the logical file I am restoring to the
> location of the physical database file I am restoring to (as per the
> prompt I
> am receiving)
> When it say "MOVE", will this in fact move the file over & possibly damage
> the database from which the restore is being taken? Does it move any files
> or
> just copy?
> Is there any danger here?
> Below is what I'm doing:
> RESTORE DATABASE oneDB
> FROM DISK = 'C:\myPhysicalBackupFile'
> WITH REPLACE,
> MOVE 'myLogicalFile' TO 'C:\Program Files\Microsoft SQL
> Server\MSSQL\data\PhysicalFile.MDF'
>
> Many thanks for any help on this
> Ant
>|||Hi Jay, thanks very much for the reply.
It's not the Database I'm overwriting that I'm concerned about, so long as
it doesn't affect the database from where I'm using the Backup from. I was
concerned that it might damage that. Sounds safe.
Many thanks for your answer Jay.
"Jay" wrote:
> It's a little confusing the first time, but all the MOVE is doing is telling
> the engine where to place the MDF file. The FROM is the .BAK file.
> And if you're overwriting an exiting database, then yes, you're gonna whack
> it. But that is expected behavior.
>
> "Ant" <Ant@.discussions.microsoft.com> wrote in message
> news:69B97720-9594-48A8-9181-53F874B8EB3E@.microsoft.com...
> > Hi,
> >
> > I'm trying to restore a backup file to a data base on a different server
> > by
> > overwriting it.
> >
> > In order to do this I need to move the logical file I am restoring to the
> > location of the physical database file I am restoring to (as per the
> > prompt I
> > am receiving)
> >
> > When it say "MOVE", will this in fact move the file over & possibly damage
> > the database from which the restore is being taken? Does it move any files
> > or
> > just copy?
> >
> > Is there any danger here?
> >
> > Below is what I'm doing:
> >
> > RESTORE DATABASE oneDB
> >
> > FROM DISK = 'C:\myPhysicalBackupFile'
> > WITH REPLACE,
> > MOVE 'myLogicalFile' TO 'C:\Program Files\Microsoft SQL
> > Server\MSSQL\data\PhysicalFile.MDF'
> >
> >
> > Many thanks for any help on this
> >
> > Ant
> >
>
>|||Ant
Please read also
http://dimantdatabasesolutions.blogspot.com/2007/04/sql-or-windows-authentication.html
"Ant" <Ant@.discussions.microsoft.com> wrote in message
news:A48539B7-996B-4A16-8F99-1100515146C7@.microsoft.com...
> Hi Jay, thanks very much for the reply.
> It's not the Database I'm overwriting that I'm concerned about, so long as
> it doesn't affect the database from where I'm using the Backup from. I was
> concerned that it might damage that. Sounds safe.
> Many thanks for your answer Jay.
>
> "Jay" wrote:
>> It's a little confusing the first time, but all the MOVE is doing is
>> telling
>> the engine where to place the MDF file. The FROM is the .BAK file.
>> And if you're overwriting an exiting database, then yes, you're gonna
>> whack
>> it. But that is expected behavior.
>>
>> "Ant" <Ant@.discussions.microsoft.com> wrote in message
>> news:69B97720-9594-48A8-9181-53F874B8EB3E@.microsoft.com...
>> > Hi,
>> >
>> > I'm trying to restore a backup file to a data base on a different
>> > server
>> > by
>> > overwriting it.
>> >
>> > In order to do this I need to move the logical file I am restoring to
>> > the
>> > location of the physical database file I am restoring to (as per the
>> > prompt I
>> > am receiving)
>> >
>> > When it say "MOVE", will this in fact move the file over & possibly
>> > damage
>> > the database from which the restore is being taken? Does it move any
>> > files
>> > or
>> > just copy?
>> >
>> > Is there any danger here?
>> >
>> > Below is what I'm doing:
>> >
>> > RESTORE DATABASE oneDB
>> >
>> > FROM DISK = 'C:\myPhysicalBackupFile'
>> > WITH REPLACE,
>> > MOVE 'myLogicalFile' TO 'C:\Program Files\Microsoft SQL
>> > Server\MSSQL\data\PhysicalFile.MDF'
>> >
>> >
>> > Many thanks for any help on this
>> >
>> > Ant
>> >
>>sql
No comments:
Post a Comment