3

I'm considering to use MySQL Workbench at work, mainly because of the modelling tools and to easily sync the development and the production DBs. I work with another developer on the same project, and we currently use GIT to version our work. In a perfect world it would be possible just to merge different changes in the models directly within GIT, but it's not possible, since the Workbench files are binary, so now I'm looking for a team strategy to work together with Workbench, share and update the same files and still be able to work on different features.

I also tried to extract the .mwb content to version the .xml inside it, but when it comes to merging it's very difficult to edit the XML involved without breaking/corrupting it.

Any suggestion? How did you solve this problem in your team?

4
  • I think the best would be to export the sql of the schema and save it to git. – ypercubeᵀᴹ Jun 8 '15 at 11:08
  • In that way, we lose the advantage of modelling... – Alessandro Cappello Jun 8 '15 at 11:10
  • @ypercube is 100% correct. Use scripts. It is possible to generate a script from the design and also a design from the script. Your sentence of loosing modeling is nonsense. A script is generated for the changes. – Namphibian Jun 9 '15 at 5:38
  • 1
    Take the basic sakila example that is preloaded in WB, and take a look at the EER Diagram in it. That's what I call "modelling". Different layers, positioning, descriptions, labels... a visual structure of the DB followed by a proper documentation. – Alessandro Cappello Jun 9 '15 at 11:36
2

We keep an .mwb file in the repo. Our team is small and changes to the schema are rare, so we can agree who modifies the file.

If the team were bigger I would introduce a lock file in the repo that's created by a person who wants to make a change and who deletes it when the change is committed.

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.