SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Restoring just a single filegroup for support purposes


Restoring just a single filegroup for support purposes

Author
Message
David Betteridge
David Betteridge
Ten Centuries
Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)

Group: General Forum Members
Points: 1063 Visits: 1822
We have a large (ish) production database in our data centre which causes a problem when we need to restore a copy for support purposes.

Currently we have to take a backup, restore it in the data centre. Drop some large tables. Back it up again and then copy it locally.

As this approach isn't ideal (!) I was wondering if we could improve things with the use of filegroups. I could add an additional filegroup to the database and then move the large tables onto the new filegroup. For our support team they could just backup the original filegroup and restore it locally.

The only problem I can see is that we might need to create the missing tables in order for our application to function. (ie. we need the tables but not the data).

I've done some tests and I can't seem to recreate the table/ drop the old table / drop the old file / drop the old filegroup as the filegroup is offline.

For example
"Cannot drop the table 'dbo.LargeTable' because at least part of the table resides on an offline filegroup."

I tried restoring the database with and without the PARTIAL keyword. I've also tried attaching and detaching the restore database without success.

I've attached a script used for my tests

Any advice?

thanks in advance

David
Attachments
Multiple Filegroup Test.txt (16 views, 4.00 KB)
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search