0

In SQL 2012 can you replicate sequence objects, and if so do changes to the sequence (including consumption of values) get replicated?

If not is there a good reason why this was not included?

2

No, sequences are not valid as articles for any type of replication.

I don't have a good reason for you (yet). But I'm curious what the purpose of replicating the sequence itself would be. If your intention is to utilize the same sequence on the subscriber to populate other tables there that aren't replicated, this wouldn't really work unless you had some way to notify the source sequence that you've used some values. You could always call a stored procedure on the publisher that generates a new sequence value there, and use it on the subscriber.

  • The purpose is because we have existing code written in informix that we are migrating to SQL server and replication. It will be difficult to go back and change it all. I would have thought a way it could work is like the identity columns, allocate a range for each subscriber and the server knows about those ranges etc. – peter Jun 26 '12 at 4:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.