Do changes User Defined Data Types get replicated by default in Tx Replication?

  • Just as the title says. I have a database that heavily uses UDDT's. We replicate it to a RDB for business intelligence, etc. We recently had a schema change that increased the length of a VARCHAR UDDT from 30 to 60. During deployment, we dropped the publication containing that article, applied the dacpac, and recreated the original publication, generating a new snapshot in the process. After the subscriber intiailized, it started generating data conversion errors. Finally tracked it down...on the OLTP publisher, someone had entered data that was longer than 30 characters and, because the RDB subscriber's definition of the UDDT was still 30, the conversion failed. Why didn't the UDDT definition get replicated during initialization? It's a fairly vanilla publication. We don't do much filtering. Is there an option that I missed?

  • Yes and no. If you've moved the UDTT already to the subscriber, this should work. Replication moves data, not really schema, though some changes flow through. I don't think UDTTs do.

    https://social.msdn.microsoft.com/Forums/sqlserver/en-US/069af16b-f56a-4b44-b884-f638af53c506/transactional-replication-and-userdefined-data-types-and-table-types?forum=sqlreplication

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply