English 中文(简体)
SQL Server 2008 Replication (avoiding reinitialization)
原标题:

I m trying to determine if there s a better way to handle replication than the way we re currently doing things.

We re essentially trying to determine 2 things:

  1. Is there any way to add an existing column from a table to replication without reinitializing the whole publication
  2. Can you just select a specific article to reinitialize instead of all of the articles in a publication?

(I m a bit new to replication... trying to get up to speed, so I apologize if my terminology doesn t make sense)

Right now we have about 30 publications so that if any have to be reinitialized there s a minimal impact... because several of our tables are pretty massive. We d prefer to only have several publication.

Any ideas would be greatly appreciated.

Update

When we try to add a column to an article we receive the message:

You have changed one or more properties that require all subscriptions to be reinitialized. Saving these changes marks each subscription that supports automatic reinitialization to be reinitialized from a snapshot the next time its Distribution Agent runs. You must run the Snapshot Agent to generate the snapshot.

We want to avoid reinitializing all subscriptions.. we re using transactional replication... again we want to add an existing column to an existing publication without having to reinitialize all subscriptions.

最佳回答

What kind of replication? Snapshot, Merge, Transacitonal, Peer-to-Peer?

1) Yes. See Making Schema Changes on Publication Databases:

  • To add a new column to a table and include that column in an existing publication, execute ALTER TABLE ADD . By default, the column is then replicated to all Subscribers. The column must allow NULL values or include a default constraint.
  • To include an existing column in an existing publication, use sp_articlecolumn (Transact-SQL), sp_mergearticlecolumn (Transact-SQL), or the Publication Properties - dialog box.

2) It depends on the replication type. See Reinitializing a Subscription:

Reinitializing a subscription involves applying a new snapshot of one or more articles to one or more Subscribers: transactional and snapshot replication allow individual articles to be reinitialized; merge replication requires all articles to be reinitialized.

问题回答

暂无回答




相关问题
Export tables from SQL Server to be imported to Oracle 10g

I m trying to export some tables from SQL Server 2005 and then create those tables and populate them in Oracle. I have about 10 tables, varying from 4 columns up to 25. I m not using any constraints/...

SQL server: Can NT accounts be mapped to SQL server accounts

In our database we have an SQL server account that has the correct roles to access some of the databases. We are now switching to windows authentication and I was wondering if we can create a NT user ...

SQL Server 2000, ADO 2.8, VB6

How to determine if a Transaction is active i.e. before issuing Begin Transaction I want to ensure that no previous transaction are open.. the platform is VB6, MS-SQL Server 2000 and ADO 2.8

热门标签