Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I have a empty database called MASTERDB and around 10, or more, slave databases that are copies of the MASTERDB database.

MASTERDB will be always empty, as I only need the schema. No data is going to be replicated/mirrored.

The scenario:

  • I create a new table on MASTERDB and I want that table to be created on those 10 tables automatically
  • If I change a field on MASTERDB, replicate the changes for all the other databases

I have looked at Mirroring and Replication, but I could not determine if these will do what I want.

Thanks in advance

share|improve this question
    
What would happen if one of the changes to MASTERDB worked in only 9 of the 10 databases? (lets say a user process blocked the update) I agree with Remus below. This is a change control problem. –  datagod Dec 14 '11 at 22:38
add comment

migrated from stackoverflow.com Dec 14 '11 at 21:41

This question came from our site for professional and enthusiast programmers.

1 Answer

up vote 2 down vote accepted

Neither mirroring nor replicaiton are appropiate here. Mirroring creates identical physical copies of the database. Replication is good at replicating data, but falls short exactly at replicating schema changes, so you would use the very wrong tool for the job.

What you describe is a a problem of change control, not replicaiton. You should approach it as such. My favourite approach is described in Version Control and your Database. Brent Ozar PLF's last video also addresses the same problem: Coping with Change Control Video.

share|improve this answer
    
Thank you! I'm going to check out the links and let you know. –  Diego Vieira Dec 14 '11 at 22:36
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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