This topic has been archived. It cannot be replied.
-
工作学习 / 学科技术讨论 / Do replicated table data need identical in SQL server 2005?Hi, friends,
In SQL server 2005, I have case to build new DB in another location and have replication with
existed DB. They have same schema. My approach is:
1. backup the existed DB, restore to new DB
2. delete some old data in new DB - existed DB keeps 10 years data, new DB
maintain the recent 3 year data.
3. make two DB replication in sync - bi-direction transactional or merge
type
Does this work in not-identical data DB replication?
Thank you
-skylei(sky);
2010-8-11
{466}
(#6222702@0)
-
from my database replication experience around 9 years ago,
(1) You don't need to backup and restore - the replication process creates the target DB(2) You don't need to delete the old data on the target side - you can specify a SQL condition to replicate only the most recent 3 years of data
(3) Not sure what you mean by not-identical. If you're referring to the 10 vs 3 years of data, no problem.
-renjl0810(Virtual Void);
2010-8-11
{254}
(#6222924@0)
-
renjl0810, thanks for great idea. It is very helpful. Could I think the process would be: 1) create new empty DB, 2)make replication with condition of 3 years data, then start to get new data coming synchronous in the two DBs.
-skylei(sky);
2010-8-11
(#6222993@0)
-
renjl0810, in (1), as my replications are just applied to some tables, it looks the other static tables and data cannot be created by replication process. Your idea?
-skylei(sky);
2010-8-12
(#6224659@0)
-
Did you configure the replication of those static tables and how did you get those tables - by backup/restore or replication?If you created those tables by backup/restore without replication, certainly the tables won't be refreshed. Even you created the tables through replication, the table won't be updated as they're static until there are updates at the source side.
Hopefully I answered your question.
-renjl0810(Virtual Void);
2010-8-12
{288}
(#6224994@0)
-
renjl0810, your answer is really helpful. That means I could set the replication to all tables even some are static data tables. Thank you.
-skylei(sky);
2010-8-12
(#6225078@0)