2

Lets assume the following:

  • 5 devs all working on laptops
  • Each develops/debugs on Azure compute emulator (code) and SQL Server (db) - both running locally on their laptops.

I'd like to have

  • These 5 SQL 'Servers' need to sync with each other
  • BONUS: If the 5 SQL servers can also sync with (non-production) Azure SQL database!

How can I set this up? The way we're setup, all dev's eventually diverge from the 'reference' database (both schema and data) and pruning it is a PITA. I'm hoping there are some tools to alleviate this issue.

2 Answers 2

3

Developers should produce code, and there are obviously many ways to sync code changes (source control). Never touch the database. Ever. If they need any change in the database, modify the code that deploys/upgrades the database. Rails's Migrations are an excellent example of doing it the right way. Visual studio has Database Projects. You can always roll your own custom solution. Post-fact comparison tools I don't like much, but you can say is a personal opinion.

1
  • 2
    "Visual studio has Database Projects" ... yup! We ended up going that route so every database change is documented and code-reviewed. It is brilliant and I'm surprised it doesn't get more blog/press coverage... Commented Mar 29, 2013 at 16:59
1

I've been having a similar issue with 8 devs and we have been working through RedGate Data Compare/RedGate Source Control. We have reviewed using it in Prod with synching up multiple environments, and doing rollouts/deployments/rollbacks with it. Outside of a few bugs and setup nuances it's been a great tool. It's probably one of the most widely used out there actually. I also asked around and there's generally 2 options:

-Roll your own. I've spoken with employees who worked in high positions at Yahoo/Herbalife, and both had their own in house tools. The Yahoo one was pretty well developed but the Herbalife one was limited.

-Use RedGate. Schema/Data compare can help you synch those up, but using source control in the multi-developer model would probably be what you are looking for.

They have lots of free trials and you can extend your trial by typing in "I need more time" as the passcode. Their support guys are good, but sometimes slow in response as they are based mainly in the UK. http://www.red-gate.com/products/sql-development/

2
  • 3
    Visual Studio also has a "Database Projects" feature that you might want to evaluate. It allows for schema comparisons, reconcilliation, producing scripts, etc. and leverages whatever source control you are using. Commented Nov 29, 2012 at 21:14
  • Thanks Darin, I'm going to look into it right now actually! Commented Nov 29, 2012 at 21:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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