Length of LOB data to be replicated exceeds configured maximum 65536

I have a table in which one column datatype is ntext. The replication was created while back. Yesterday when I was deploying some DML scripts , the script failed with below error.


Msg 7139, Level 16, State 1, Line 186
Length of LOB data (71308) to be replicated exceeds configured maximum 65536.
The statement has been terminated.

The error itself tells us that the size of the text is greater than configured size. So where do we need to make change to make this work?

By default the maximum size is set to 65536 bytes as we can see in below fig for SQL Server property. Right Click on SQL Server Instance and go to properties to see below window.
Fig 1: Max Text Replication Size SQL Server Property

Set the Max Text Replication Size property to -1 that means that there is no size limit.

Change the value from 65536 to -1 and then hit Ok as shown below.

Fig 2: How to set Max Text Replication Size in SQL Server

Once the change is done, you are good to go with your insert or update statements.


No comments:

Post a Comment