tags:

views:

41

answers:

2

Hi,

Can some body please, give me idea on how can I do a schema compare between the build script in TFS and the database in the server for that build.

Thanks

A: 

Generally speaking, you cannot reliably compare DB schemas: for instance, renames will never be handled correctly. What you need is a database migration tool, which will allow you to apply required changes to a particular database instance in a controlled and reliable manner. I personally use my own project called Wizardby to do that.

Anton Gogolev
A: 

This would take some time, but you could run the build script to make an empty test database, then script that out with Management Studio (or SMO) scripting, to a text file. Script out the prod DB and compare the scripts with a diff tool. Clunky, but it works :-)

onupdatecascade