Code Monkey home page Code Monkey logo

Comments (1)

michaelsogos avatar michaelsogos commented on May 25, 2024

Dear @ivanDespot

Thanks for using my tool.
The answer is no.

When I started developing pg-diff I was coming from years using other tools, and all of them implemented classical migration strategy based on Up() and Down() functions.

I don't agree totally with rollback strategy bacause essentially it cannot work in every case and is very dangerous.
From my experience, I never needed to deploy a sql patch that wasn't well tested; this works for me because I know what I did in develop machine and tested again in develop machine before commit my changes.

That's why I choose to not include a rollback strategy, but hey! You can still make a new following patch to revert back changes.

Let me try to explain a possible way to work.
Image that you develop a software based on pgsql.
You should have two databases, one to make changes and very important never connected with software; another one to compare with the above db, make patch, try to apply that patch and connected with your software.
As soon as possible you start debugging or whatelse in order to check your changes.
If changes are OK than you can commit sql patches on source code repository and then share it with your team in case, else delete created patch from your workspace.

In case you use this tool just for databases as diff tool, then you should not apply patch if unsure, but in any case try an approach "fast-forward" always, that in other terms means you should create a new patch to revert back changes.

Make it sense for you?

from pg-diff.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.