• jesijesijesi (12/15/2014)


    Hello,

    If i understand correctly, you are planning on a mirrored subscriber. if that is the case, and there is a failover of the subscription database, then you would have to remove the old subsciption to the original principal and create a new subscription to the new principal db using the "initialize from lsn" option, so that you do not have to reinitialize the whole subscription and only get the changes after it has failed over.

    we can get the lsn which was last replicated successfully from MSreplication_subscriptions, transaction_timestamp column

    so when creating the new subscription to the new principal use the above value to fill @subscriptionlsn

    exec sp_addsubscription @publication = N'test', @subscriber = N'testa', @destination_db = N'test',

    @subscription_type = N'Push', @sync_type = N'initialize from lsn', @article = N'all',

    @update_mode = N'read only', @subscriber_type = 0,@subscriptionlsn=0x0000001A000000890003000000000000

    Thanks a lot !!