Saturday, February 25, 2012

Move database to another partition

25degc wrote:
> I have recently installed SQL Server 2005 Standard Edition on a server wit
h 2
> partitions. I then installed Sharepoint which installed a database and put
it
> in the default location on the c: partition. I would like to move this to
d:.
> I have tried to do this by detaching and attaching, and also by backing an
d
> restoring, but both the attach and the backup dialog boxes only allow me t
o
> browse the c: drive. Is this a feature of Standard Edition? Do I need to u
se
> Enterprise? Or is there a configuration setting I can change somewhere?
> TIA
Not sure why you can't browse your other drive, but a workaround would
be to not use the GUI to do this. Instead use the SQL commands to
detach/reattach the database:
EXEC sp_detach_db DBname, 'true'
Copy the files from C: to D:
EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
@.filename2 = 'D:\LDFFile'I have recently installed SQL Server 2005 Standard Edition on a server with
2
partitions. I then installed Sharepoint which installed a database and put i
t
in the default location on the c: partition. I would like to move this to d:
.
I have tried to do this by detaching and attaching, and also by backing and
restoring, but both the attach and the backup dialog boxes only allow me to
browse the c: drive. Is this a feature of Standard Edition? Do I need to use
Enterprise? Or is there a configuration setting I can change somewhere?
TIA|||25degc wrote:
> I have recently installed SQL Server 2005 Standard Edition on a server wit
h 2
> partitions. I then installed Sharepoint which installed a database and put
it
> in the default location on the c: partition. I would like to move this to
d:.
> I have tried to do this by detaching and attaching, and also by backing an
d
> restoring, but both the attach and the backup dialog boxes only allow me t
o
> browse the c: drive. Is this a feature of Standard Edition? Do I need to u
se
> Enterprise? Or is there a configuration setting I can change somewhere?
> TIA
Not sure why you can't browse your other drive, but a workaround would
be to not use the GUI to do this. Instead use the SQL commands to
detach/reattach the database:
EXEC sp_detach_db DBname, 'true'
Copy the files from C: to D:
EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
@.filename2 = 'D:\LDFFile'|||Thanks. This highlighted an issue with the d: drive. Although
readable/writable through Windows I decided to reformat, and now it is
working fine.
Thanks for your help.
"Tracy McKibben" wrote:

> 25degc wrote:
> Not sure why you can't browse your other drive, but a workaround would
> be to not use the GUI to do this. Instead use the SQL commands to
> detach/reattach the database:
> EXEC sp_detach_db DBname, 'true'
> Copy the files from C: to D:
> EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
> @.filename2 = 'D:\LDFFile'
>|||Thanks. This highlighted an issue with the d: drive. Although
readable/writable through Windows I decided to reformat, and now it is
working fine.
Thanks for your help.
"Tracy McKibben" wrote:

> 25degc wrote:
> Not sure why you can't browse your other drive, but a workaround would
> be to not use the GUI to do this. Instead use the SQL commands to
> detach/reattach the database:
> EXEC sp_detach_db DBname, 'true'
> Copy the files from C: to D:
> EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
> @.filename2 = 'D:\LDFFile'
>

No comments:

Post a Comment