Setting a property value on an object fails: Maximum allowable length exceeded (Microsoft SQL Server database)

Attempting to set a property value on an object results in an error indicating that the maximum allowable length has been exceeded.

Symptoms

When you attempt to set the value of a property on an object in an object store with Microsoft SQL Server as the database engine, an error occurs indicating that the requested insertion would cause a particular row in the database to exceed the maximum allowable length. The insertion fails.

Causes

Microsoft SQL Server limits the length of database rows to a maximum of approximately 8060 bytes.

Resolving the problem

Reduce the length of the property value that you are attempting to set. If reducing the length does not resolve the problem, then you need to reduce the lengths of the existing values of associated properties in the database row so that the overall length does not exceed 8060 bytes.

For related information on metadata design considerations that might have helped to avoid this problem, see Minimize database row sizes.