| Author |
Message |
chilversc
Joined: 30 Nov 2011 Posts: 1
|
Posted: Wed Nov 30, 2011 4:19 pm Post subject: Controlling script folder evaluation order |
|
|
How do I control the order the scripts are evaluated?
I like to store my foreign keys separately to the tables, so I'll have 2 folders, "Tables" and "Foreign Keys".
However, when I try to compare a database against the script folder it complains about table "Foo" not existing for each of the foreign key's "ALTER TABLE Foo" statements.
I've determined that it is an ordering problem since if I rename the directories "01_Tables", "02_Foreign Keys" the script parses correctly.
I don't like having to rename the directories like this though since I can't see anywhere in the documentation that this behaviour is guaranteed thus it seems to me like I would be relying upon undefined behaviour. |
|
| Back to top |
|
 |
jgonzalez
Joined: 31 Oct 2011 Posts: 5
|
Posted: Thu Dec 01, 2011 4:47 am Post subject: |
|
|
Is there a reason you have to have them separate? SQL Compare always generates the foreign key statements after the table in every script I have ever seen.
We script out our entire database into an "Objects" directory and let SQL Compare organize the sub directories beneath it however it wants. |
|
| Back to top |
|
 |
|
|
All times are GMT + 1 Hour
|
| Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group