Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 SQL Server Administration (2008)
 Restore filegroup

Author  Topic 

cardasim
Starting Member

1 Post

Posted - 2009-08-03 : 10:36:45
Hello,

I would appreciate so much your help regarding some backup/restore issues that I encounter.

The database contains two filegroups, PRIMARY and CONFIG. Each filegroup consists of one physical file. Below, the concrete structure of the database:
T3
- PRIMARY
- Primary (T3.mdf)
- CONFIGURATION
- Configuration (T3_Configuration.ndf)
T3_log (T3_log.ldf)

Scenario A
1. The deployment team deploys the database, configures the system and tests the routine use-cases;
at this time both PRIMARY and CONFIGURATION filegroups are updated
2. The system must go in production, so we want to keep the config data from the CONFIGURATION filegroup and to get rid of the production data produce during the tests
Question: can we do this? Can we keep the actual state of the CONFIGURATION fielgroup and to restore the PRIMARY filegroup to a previous point in time, before any test data was produced? If yes, you could please describe the steps?

Scenario B
1. The deployment team succesfully runs in production at customer A.
2. One month later, the deployment team has to install the product at customer B.
They want to "reuse" the configuration data from customer A.
Question: it is possible to backup the CONFIGURATION filegroup from customer A,
then go to customer B, create a new database and then restore only the CONFIGURATION filegroup that already has the configuration data inside?

Would be wonderful to get some answers for those questions. If none of the scenarios are solvable using filegroups, what would be your suggested solution.

Thank you very much!

mcrowley
Aged Yak Warrior

771 Posts

Posted - 2009-08-03 : 16:52:50
Scenario A: no. This can not be done. SQL Server (and just about every other system on the market) uses a sort of counter called an SCN (System Change Number) to govern recovery. All pages in the database must reflect the same SCN after recovery ends, or the database can not be opened. It is then marked suspect. To achieve what you are after, you should export the data from the tables in the CONFIG filegroup probably to text files, and re-import them when you go to production.

Scenario B: Again, no. Same reasons.
Go to Top of Page
   

- Advertisement -