0

Assume that I have deployed a web project one year ago. And I developed during one year, and now I want to deploy new version of web project.

My question is how can I find the differences between new database and old database which includes added stored procedures, new columns, new tables, deleted tables, added views etc.

I want to do deployment from web-site which is coded MVC 5.

Are there any 3rd part tool in order to achieve that deployment?

UserStackk
  • 75
  • 1
  • 1
  • 6
  • See [Free Tool to compare Sql Server tables](http://stackoverflow.com/questions/193438/free-tool-to-compare-sql-server-tables), [What is best tool to compare two SQL Server databases (schema and data)?](http://stackoverflow.com/questions/685053/what-is-best-tool-to-compare-two-sql-server-databases-schema-and-data), [How to compare two folders for similar files based on name in C#?](http://stackoverflow.com/questions/4374887/how-to-compare-two-folders-for-similar-files-based-on-name-in-c), [WinMerge](http://winmerge.org/). What have you tried? – CodeCaster Dec 12 '13 at 13:25

2 Answers2

2

Red Gate SQL tools are fantastic. Have a look at their SQL Compare tool.

I don't have any affiliation to Red Gate, I just like their tools

Visual Studio 2012 also contains Schema Compare tools, you can give them a try a as well. Find it in the main menu -> SQL -> Schema Compare

Philip Fourie
  • 96,182
  • 10
  • 57
  • 81
  • I want to do it from web interface clicking one button. Is it possible? Assume that there is a deployment module, you define new dlls and new db. – UserStackk Dec 12 '13 at 14:03
  • @UserStackk - yes, this is possible using Red Gate Deployment Manager: http://www.red-gate.com/delivery/deployment-manager/ – David Atkinson Dec 12 '13 at 22:45
0

You can use xSQL Software's Schema Compare SDK - with just a few lines of code you can do the comparison and synchronization from your app. However, keep in mind that wherever you might be doing the comparison and sync from you will need to have access to both servers/databases you are trying to sync.

If you do not have direct access to both sides you can do the following: - create a job that takes a schema snapshot of the source DB (you can do this using the above mentioned SDK or using the command line of the Schema Compare tool) and transfers the snapshot via ftp to the target server; - on the target server your code which uses xSQL Schema Compare SDK compares the snapshot to the target database and pushes the changes to the target.