Controle the order of elements in SQL export.

Tell us what features you'll want

Controle the order of elements in SQL export.

Postby vinny42 » Sun Dec 25, 2011 6:18 pm

The current version of DBSchema dumps out all the SQL in a single file and gets the order wrong for PostgreSQL;
the tables are created before the the sequences, but a table can require the existence of a sequence if it uses nextval() as a default value in a column.

Obviously dbschema cannot analyse all dependencies but I know the correct order for my database so it would be very nice if we could manually define (or at least override) the export-order.
vinny42
 
Posts: 1
Joined: Fri Dec 23, 2011 7:56 pm
 

Re: Controle the order of elements in SQL export.

Postby Martin.Sawyer » Tue Dec 27, 2011 8:04 am

Hello,

Your feature requested has been submitted to our software engineers.

Regards,

Martin
Martin.Sawyer
 
Posts: 21
Joined: Mon Dec 19, 2011 11:46 am
 

Re: Controle the order of elements in SQL export.

Postby stathis » Thu Jan 05, 2012 4:40 pm

+1 vote for this feature.

I have created a schema in my development server but i cannot use the dbschema to create it in the production server, because of the order.

More specifically, trying to create a table before the creation of referenced tables. A possible solution might be the exposure of an API as pointed in another feature request, where someone could colntrol the order by Java.
stathis
 
Posts: 1
Joined: Thu Jan 05, 2012 4:33 pm
 

Re: Controle the order of elements in SQL export.

Postby flogger123 » Sun Feb 05, 2012 4:39 pm

Add me up. This would save us so much time when this will be available.
You're never a loser until you quit trying. Image
flogger123
 
Posts: 44
Joined: Mon Jan 23, 2012 5:25 pm
 

Re: Controle the order of elements in SQL export.

Postby Martin.Sawyer » Mon Feb 06, 2012 8:53 am

+1 Vote for this feature has been added
Martin.Sawyer
 
Posts: 21
Joined: Mon Dec 19, 2011 11:46 am
 

Re: Controle the order of elements in SQL export.

Postby donose.mihai » Wed Oct 10, 2012 1:37 pm

The sequence problem should be fixed. Please upgrade to the latest version.

Go to Edit -> Configuration -> Automatic Updates -> Update Source -> Beta -> Save and Close | go to Help -> Check for updates, after the updates completes, restart DbSchema.

The second reply, about the table creation order should also be fixed. DbSchema checks the table order and keeps track about foreign keys.
Can you please provide a sample project where the tables are created in the wrong order ? We couldn't reproduce the problem on our side.
donose.mihai
 
Posts: 362
Joined: Thu Apr 07, 2011 11:05 am
 

Return to DbSchema Features

cron