Git Product home page Git Product logo

Comments (7)

GitStorageOne avatar GitStorageOne commented on June 26, 2024 1

Now that you mentioned these steps, did you know the objects' metadata handling feature? I think it can help you while the plugin isn't developed: https://pgmodeler.io/support/docs/612-objects-metadata-handling?v=1.1.0

Wow, this is what I need and it works, I can organize my workflow.
I am closing this issue, additional temporary features are not needed,
Will use what is implemented and wait for the synchronization plugin, thanks.

from pgmodeler.

rkhaotix avatar rkhaotix commented on June 26, 2024

Thanks for your suggestion @GitStorageOne

I'll consider it on the next patch (1.1.1) or if it takes too much time to implement I'll move it to 1.2.0, but I believe this is something quite easy to add.

from pgmodeler.

rkhaotix avatar rkhaotix commented on June 26, 2024

@GitStorageOne I added some improvements related to this issue on 1.1.1 (released today) and I would like your feedback if possible! :)

pgModeler 1.1.1 now does not touch the current position of the original object when importing new objects to the working model. There is also an extra option to put the imported objects in random positions. The "Auto browse" feature has been fixed and now it is considered in both database import form and model/db diff form.

from pgmodeler.

GitStorageOne avatar GitStorageOne commented on June 26, 2024

@rkhaotix Well, for me it doesn't work, unfortunately.
Steps:

  1. Create database model programmatically.
  2. Import model in pgModeler, place tables to get pretty and readable view.
  3. Add the new column to the some table within model programmatically.
  4. Import model in pgModeler, with option import objects to the working model.
  5. I don't see the new column in the table within pgModeler model.
    Can't check import log, because pgModeler closes window right after import.
  6. If I delete table from model programmatically and re-import model to pgModeler with option import objects to the working model - table stays.

So, 5 is just a bug as I understand.
But 6, i suppose it is by design, if so, would be great if you could add option drop existing objects from model under Import objects to the working model.
Should be the way to reload model entirely from database and restore table sizes and positions (and positions of all objects that could be restored), so continuous development become possible.
All that is required is to save the position and size data from the pgModeler model, and after re-import model from DB, apply the previous position and size settings to the matched objects.

from pgmodeler.

rkhaotix avatar rkhaotix commented on June 26, 2024

Hmmm ... Now I understand what you want.

  1. Apply changes made in the database to the model. This is the inverse of how diff tool works today, applying to the database the changes made in the model.

  2. Avoid changing the object positions in the model when importing new objects.

  3. Make the import form obey the " auto browse" option of the connections used in the process.

The items 2 and 3 are implemented on pgModeler 1.1.1. The item 1, it's not fully supported, that's why you're no seeing the new column on the model. pgModeler will not import new columns alone due to the way the reverse engineering works.

I have plans to create a plug-in that will implement a full featured database -> model sync tool. For now, I will review the import process and try to improve it in the way you need.

from pgmodeler.

GitStorageOne avatar GitStorageOne commented on June 26, 2024

Thanks, 2 and 3 are definitely works great.
As you are going to develop a whole new plugin for "database -> model sync",
drop existing database objects under Import objects to the working model could be an option for now.
What that option could do:

  • Cache position and size data of the database related objects;
  • Remove database related objects and not touch UI elements like Textboxes, e.t.c.
    All changes that was made to any database related objects (within pgModel) will be lost, f.e. additional columns or new tables.
  • Reload database related objects and re-apply position and size data.
  • At the end we get updated database model view, and even visual remarks will be still there.
    Also please add option somewhere to leave import form opened so users who interested to debug would be able to review the log.

Full featured plugin, that you announced, is absolutely awesome, will do it's own complicated job.
I'm pretty excited to get it in the future, luckily I recently decided to support project again and opted in to lifetime updates :)
I can additionally help with polishing UI, by reporting some bugs and thoughts.
I have few for new backup tool form.

from pgmodeler.

rkhaotix avatar rkhaotix commented on June 26, 2024

As you are going to develop a whole new plugin for "database -> model sync",
drop existing database objects under Import objects to the working model could be an option for now.
What that option could do:

  • Cache position and size data of the database related objects;
  • Remove database related objects and not touch UI elements like Textboxes, e.t.c.
  • All changes that was made to any database related objects (within pgModel) will be lost, f.e. additional columns or new tables.
  • Reload database related objects and re-apply position and size data.
  • At the end we get updated database model view, and even visual remarks will be still there.
    Also please add option somewhere to leave import form opened so users who interested to debug would be able to review the log.

Now that you mentioned these steps, did you know the objects' metadata handling feature? I think it can help you while the plugin isn't developed: https://pgmodeler.io/support/docs/612-objects-metadata-handling?v=1.1.0

Full featured plugin, that you announced, is absolutely awesome, will do it's own complicated job.
I'm pretty excited to get it in the future, luckily I recently decided to support project again and opted in to lifetime updates :)

And I'm grateful for the financial support! :D

I can additionally help with polishing UI, by reporting some bugs and thoughts.
I have few for new backup tool form.

I'll be waiting for that! ;)

from pgmodeler.

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.