Q

Merge replication

If I use Merge Replication in SQL Server, which "Data Types" will be synchronizing? Is it possible to synchronize "Text" Data Type if I use Merge Replication?

Merge replication supports the replication of text and image columns only if they have explicitly been updated by an UPDATE statement. Using the WRITETEXT and UPDATETEXT operations alone will not propagate the change to other sites. If your application uses WRITETEXT and UPDATETEXT to update the text columns, then explicitly add an "UPDATE statement" after the text operations, within the same transaction, to guarantee that the change will be propagated to other sites.

For example, updating the review column of the employees table:

 BEGIN TRAN DECLARE @mytextptr varbinary(16) SELECT @mytextptr = TEXTPTR(review) FROM employees WHERE emp_id = '444-55-6666' IF @mytextptr IS NOT NULL UPDATETEXT employees.review @mytextptr 0 NULL 'Terrific job this review period ....' -- Use of Update to ensure that the text gets propagated to other Subscribers UPDATE employees SET review = review WHERE emp_id = '444-55-6666' COMMIT TRAN

I hope this example works well for you.

 

For More Information

This was first published in May 2001

Dig deeper on Microsoft SQL Server Installation

Pro+

Features

Enjoy the benefits of Pro+ membership, learn more and join.

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchBusinessAnalytics

SearchDataCenter

SearchDataManagement

SearchAWS

SearchOracle

SearchContentManagement

SearchWindowsServer

Close