SQL Power Business Intelligence Productivity Tools
Company OverviewBusiness Intelligence Productivity ToolsQuick-Start Implementation ServicesDemos & TurotialsFrequently Asked Questions (FAQ)Open Source Community ResourcesSQL Power ForumImplementation & Technology PartnersGet SQL Power SoftwareContact Us

SQL Power Software Forum

SQL Power Software Forum

  [Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [Groups] Back to home page  [Register] Register /  [Login] Login 
Compare DM - DDL Generation could be optimized  XML
Forum Index » SQL Power Architect Suggestions
Author Message
castorp


Joined: 2008-03-06 13:38:06
Messages: 129
Offline

Hi,

I noticed that the generated DDL when comparing data models (at least for Oracle and Postgres) is a bit "complicated".

When a table (or column) is dropped, the DDL first contains drop statements for any related constraint. While that is technically correct and is probably needed for e.g. SQL Server or MySQL, Oracle and Postgres offer a CONSTRAINT option when dropping objects.

The resulting DDL script would be a lot smaller if the tables are dropped right at the beginning using "DROP TABLE the_table CASCADE" (Postgres) or "DROP TABLE the_table CASCADE CONSTRAINTS" (for Oracle).

Then all ALTER TABLE ... DROP CONSTRAINT for that table could be removed from the script, making it a bit more concise.

The same is true for dropping columns (simply add the CASCADE keyword and "forget" about any constraint to that column)

Regards
Thomas
 
Forum Index » SQL Power Architect Suggestions
Go to:   
Powered by JForum 2.1.8 © JForum Team