Export automatically DDL on commit/save project

#1

When managing large number of object (hundreds) you cannot all the time going to export DDL scripts, but would like to establish automatic export on every commit to TeamWork server or simply save of project.

Is there any kind of API which can be used for such purpose.

It will simply export changed models DDL on the disk, or it can simply regenerate everything.

There are certain groups of exportable SQL statements:
DDL - Create, Drop
DML - Insert, Update, Delete Select

It should produce for each ERD physical diagram 6 SQL files on save/commit.

Any ideas how to achieve this?

0 Likes

#2

Interesting idea.

At the time of writing I don’t know how feasible it is, but I have done a little digging into the Plugin API and some things seem possible. The DatabaseManager interface provides methods such as generateCreateSQL() which might make this possible.

However… I don’t see anything that is specifically related to exporting SQL code into a sql datafile and at this time I’m not sure if these methods do the same as (for example) the ‘create database’ and ‘generate SQL’ options which can be found in the Tools -> DB menu and a diagram context menu respectively.

One way to find out though; I added the idea to my Win10 todo list and I’ll probably look into it a bit further tomorrow evening

1 Like

Support for Hive and Graph Databases
#3

@ShelLuser - well I will look into DatabaseManager interface, thx for hint and test this.

This is related to topic regarding Hive support in other thread:

The whole DDL release automated pipeline with Postgres and Hive support (graph is another story for later examination…)

0 Likes