Red Gate forums :: View topic - Bug perhaps - not sure whats going on
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SQL Source Control 1
SQL Source Control 1 forum

Bug perhaps - not sure whats going on

Search in SQL Source Control 1 forum
Post new topic   Reply to topic
Jump to:  
Author Message
gsuttie



Joined: 30 Nov 2005
Posts: 45
Location: Glasgow, Scotland

PostPosted: Thu Nov 11, 2010 4:28 pm    Post subject: Bug perhaps - not sure whats going on Reply with quote

If I have say 100 tables in my list of tables within SQL Management Studio and I choose one in the middle of the list and choose to design the table, I then add a column and click save - on the left hand pane (list of tables) the name of the table I just changed is no longer there - I know that if I then refresh the list of tables it comes back but its slightly worrying when the table looks likes it just been deleted - is this dropping the table to recreate it and thats why the names dissappears form the ilst of tables?

Cheers
Gregor
Back to top
View user's profile Send private message
markv



Joined: 06 Jul 2010
Posts: 14

PostPosted: Fri Nov 12, 2010 5:30 pm    Post subject: Reply with quote

In SSMS it will not drop a table unless you have the "Allow DROP" option ticked with in the preferences. Also, the only time it will drop a table and recreate is if there is a need to.

Adding a new column to the end of the database table does not but if you drag it around to place it in a specific column order this will. Also, other options you specify as part of the column may cause a drop.

The best way to see this is by either keeping the Allow Drop option disabled or generating a script of the changes before applying them. If the script creates a temporary table then inserts data from the existing table, it is going to be dropping and recreating.
Back to top
View user's profile Send private message MSN Messenger
eddie davis



Joined: 14 Jun 2006
Posts: 937
Location: Red Gate Software

PostPosted: Mon Nov 15, 2010 1:03 pm    Post subject: Reply with quote

Thank you for your post into the forum.

SQL Source Control makes use of the SQL Compare engine. When synchronizing two databases using SQL Compare, a table rebuild is required when the column order has changed to preserve the data in the table to be synchronized.

Therefore if you add a column to a table and you force the column order, so that the new column is added between existing columns, this will require a table re-build in the manner you have described.

Many Thanks
Eddie
_________________
Eddie Davis
Technical Support Engineer
Red Gate Software Ltd
E-mail: support@red-gate.com
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Reply to topic 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