开发者

Replication - User defined table type not propagating to subscriber

I created a User defined table type named tvp_Shipment with two columns (id and name) . generated a snapshot and the User defined table type was properly propagated to all the subscribers.

I was using this tvp in a stored procedure and everything worked fine.

Then I wanted to add one more column开发者_运维技巧 created_date to this table valued parameter.I dropped the stored procedure (from replication too) and also i dropped and recreated the User defined table type with 3 columns and then recreated the stored procedure and enabled it for publication

When I generate a new snapshot, the changes in user defined table type are not propagated to the subscriber. The newly added column was not added to the subscription.

the Error messages:

The schema script 'usp_InsertAirSa95c0e23_218.sch' could not be propagated to the subscriber. (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147201001)
Get help: http://help/MSSQL_REPL-2147201001
Invalid column name 'created_date'. (Source: MSSQLServer, Error number: 207)
Get help: http://help/207


On the publication, is the replicate_ddl option set to true? Also, what's the value for the pre_cmd value for the article in question? If neither of those point you in the right direction, take a look at the file that it says is failing. It should be a human-readable T-SQL file that's located at the distributor in the snapshot folder. If the error isn't obvious, you can try running it at the subscriber and see what it gives you. My guess is that it didn't replicate the column change, but you put an index on it which references that column. But that's just a guess.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜