Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Comparing Databases (and producing an *.sql file to make them match!) 1

Status
Not open for further replies.

BaldEddy

Programmer
Jan 11, 2002
7
CH
I am in the process of developing additional features to a client's existing database (which has been running in a production environment for several years).

When the time comes to install the additional modifications I will also be upgrading their database from SQL 7.0 to SQL Server 2K. The plan is to maintain an *.sql file that will then create all additional stored-procedures and tables, and also alter existing tables in the upgraded database to match the development database (which originated itself from the SQL Server 7.0 database from the client's site).

Producing and maintaining the *.sql file to make all these modifications is a fairly pain-free process - but time-consuming.

The question is therefore - Is there a "Compare Databases" utility that can generate the necessary *.sql script to make one database match the other, or in the very least compare two databases and verify their structure is identical??? (

Regards,

Paul Kelly.
 
Many thanks dinzana,

I'll hopefully get around to trying the free-trial sometime soon - but looks promising,

regards.
 
It is worth every penny. Believe me it has saved me hours of grief. You do have to be somewhat careful with it and create new objects in the correct order when you run scripts from the comparisons.

Usually I do tables first, then views, then stored procedures and UDFs. If I get errors, then I know that I have somethings that need to happen in a particular order, although often I can tell from the object names if I am familiar with the relationships. But sometimes you may not notcie a problem until you run the script. still fasster than doing it by hand by far.

Incidentally if I have objects in my dev db that I know I do not ever want to move to production I make sure the word test is in the object name. That way I don't accidentally move them to production.
 
I have officially joined the red-gate software fan club.

This product is excellent ( and has already eayned me £50 for suggesting we buy it!).

many thanks :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top