Red Gate forums :: View topic - Will getting latest change remove any existing table rows?
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

Will getting latest change remove any existing table rows?

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



Joined: 15 Nov 2006
Posts: 4

PostPosted: Wed Feb 09, 2011 2:41 pm    Post subject: Will getting latest change remove any existing table rows? Reply with quote

Will getting latest change remove any existing table rows in changed tables? I don't want to lose my test data.
Back to top
View user's profile Send private message
MartinU



Joined: 09 Feb 2011
Posts: 13

PostPosted: Wed Feb 09, 2011 4:54 pm    Post subject: Reply with quote

This is a must for us to be able to move to SSC from Visual Studio. The most appealing aspect of SSC is the performance compared to VS. However, if we have to replace our data each "get latest" operation then I believe the benefit will be negligible and we will stay with VS.
Back to top
View user's profile Send private message
David Atkinson



Joined: 05 Dec 2005
Posts: 1114
Location: Twitter: @dtabase

PostPosted: Sat Feb 12, 2011 6:45 pm    Post subject: Reply with quote

If I understand the question, are you asking whether 'get latest' will wipe all pre-existing data from your linked development database?

Rest assured that SQL Source Control will preserve your existing data in this circumstance. Tables will be ALTERed where possible. In some situations they will need to be rebuilt, in which case SQL Source Control will create a temporary table in which the data is copied, and then replaces it once the table has be recreated.

I'd encourage you to test the tool on a few of your own scenarios to fully satisfy yourself that the behavior is how you expect it to be, and of course let us know if it falls short.

Kind regards,

David Atkinson
Product Manager
Red Gate Software
Back to top
View user's profile Send private message Send e-mail
MartinU



Joined: 09 Feb 2011
Posts: 13

PostPosted: Mon Feb 14, 2011 1:27 pm    Post subject: Reply with quote

Correct, my concern is of existing testing data not so much the static data as we already replace thaton each Visual Studio deployment operation.

Take a c# programmer for example debugging and testing their code they may have populated their local DB with testing data. However, they need to get latest on the DB so they are certain they are coding against the most recent schema.

We would not want their test data to removed.
Back to top
View user's profile Send private message
David Atkinson



Joined: 05 Dec 2005
Posts: 1114
Location: Twitter: @dtabase

PostPosted: Mon Feb 14, 2011 1:29 pm    Post subject: Reply with quote

In that case it should be fine. The only exceptions are when you are getting latest on a table where a column has been truncated or removed. In this case the data will be lost and not recoverable by the undo feature, as it isn't in source control.

In other cases, we preserve the pre-existing data.

Kind regards,

David
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