What is the best way to keep the two database schemas in sync?

We have two SQL Server databases, one is stored in the US and changes from day to day, and the other is in India. What is the best way to keep the two database schemas in sync. Do any features like SQL Server replication help?

+2


a source to share


2 answers


If you are using replication, then when you change the schema on one side, you should republish these articles and resynchronize only the things that have changed.

If you are making changes through a script, just apply the change scripts to both databases. EDIT: In fact, if you KNOW that you are making changes to two databases, I highly recommend creating a change script that you can run on both.



If you are not sure if the schemas are in sync, we use Red SQL Gates SQL Compare . It's a fantastic tool (and no, I don't work for them)

+5


a source


Replication cannot really help if the schema changes.

Is the schema changed on both sides?



A tool like Red Gate SQL Compare or a similar tool Apex can view two databases, identify differences, and generate scripts to make them the same as the others.

+1


a source







All Articles