- Indexes can be added at the Publisher or Subscribers with no special considerations for replication (be aware that indexes can affect performance). CREATE INDEX and ALTER INDEX are not replicated, so if you add or change an index at, for example, the Publisher, you must make the same addition or change at the Subscriber if you want it reflected there.
- Beginning with SQL Server 2005, you can move or rename files without detaching and re-attaching the database, with no effect on replication.
- Take database offline
- Alter database modify MODIFY FILE ( NAME = logical_file_name, FILENAME = ' new_path/os_file_name ' )
- Take database online
- To add table in existing publication, it is not necessary to
stop activity on the publication or subscription databases in order to add
a table (or another object). Add a table to a publication through the Publication Properties -
dialog box or the stored procedures sp_addarticle and sp_addmergearticle.
- Replication functions properly using any of the recovery models: simple, bulk-logged, or full. Merge replication tracks change by storing information in metadata tables. Transactional replication tracks changes by marking the transaction log, but this marking process is not affected by the recovery model.
- If a transactional publication supports queued updating subscriptions, replication adds the column msrepl_tran_version to every table. If the table is dropped from the publication, the msrepl_tran_version column is not removed.
- Replication provides automatic identity range management for replication topologies that include updates at the Subscriber.
- There are no restrictions on the number or types of publications that can use the same distribution database. (Multiple publications can use the same distribution database).
- Replication processing resumes at the point at which it left off if a connection is dropped
- TRUNCATE TABLE is a non-logged operation that does not fire triggers. It is not permitted because replication cannot track the changes caused by the operation: transactional replication tracks changes through the transaction log; merge replication tracks changes through triggers on published tables.
- For transactional replication, bulk inserts are tracked and replicated like other inserts
- CREATE INDEX and ALTER INDEX are not replicated, so if you add or change an index at, for example, the Publisher, you must make the same addition or change at the Subscriber if you want it reflected there.
- To drop column on published table execute ALTER TABLE … DROP COLUMN at the Publisher, and the statement is replicated to Subscribers
- Replication supports restoring replicated databases to the same server and database from which the backup was created. If you restore a backup of a replicated database to another server or database, replication settings cannot be preserved. In this case, you must recreate all publications and subscriptions after backups are restored.
- To modify any column in replication
----> Alter table alter column----> Example: Alter table dept alter column Deptname varchar(100)
- How to remove replication: http://msdn.microsoft.com/en-us/library/ms152757(v=sql.105).aspx
- To add or drop column in replication, we can use Alter table (but it will not be replicated automatically) ---->Alter table dept add depttest varchar (20)