By: Greg Robidoux | Updated: 2019-09-06 | Comments (18) | Related: More > DBA Best Practices
Problem
There is often the need to compare both data and database structures from two databases either on the same server or on different servers. Most text editors have a built-in process to allow you to do a diff and identify any differences between the two files, but comparing data is not quite that easy. Using this diff process is great if you only want to compare a few files, but what if you need to scan your entire database to look for differences?
As with anything you can always create your own application to automate the comparison process. You could cursor through all of the tables read the T-SQL from one server, get the T-SQL for the same object from the other server and do a comparison. To compare the data you can write scripts that read row by row and do a comparison of the data. But why bother when there are so many products out there already.
Solution
Luckily a lot of products already exist. These products allow you to compare database objects, data, DTS scripts, servers, etc... In addition, these products are not all that expensive either. Some of the products are under $100 US and I also found a company that offers a free version, see below.
Following is a list of the various products that allow you to do comparisons:
Object Comparison
- AdeptSQL Diff (no longer available)
- AlfaAlfa Software - SQL Server Comparison Tool
- ApexSQL - SQL Diff
- Best SoftTool - SQL DBCompare (no longer available)
- Devart - dbForge Schema Compare for SQL Server
- e-Dule - DB SynchroComp
- Innovartis - DB Ghost Schema Compare
- Navicat for SQL Server
- PrimeLogics - DataVision 2007 (no longer available)
- Quest - SchemaCompare (no longer available)
- Red Gate - SQL Compare
- SQL Effects (no longer available)
- SQL Server Database Comparison Tool
- TASC - SQL Delta
- Teratrax Database Compare (no longer available)
- TulsaSoft - SQL Examiner
- Voltex Data Systems - SQLDBcontrol (no longer available)
- XpressApps - sqlXpress Diff (no longer available)
- xSQL Software - Schema Compare
Data Comparison
- ApexSQL - SQL Diff
- Aqua Data Studio
- Best SoftTool - SQL DBCompare (no longer available)
- Devart - dbForge Data Compare for SQL Server
- Innovartis - DB Ghost Data Compare
- JUXTAPPOSE
- Navicat for SQL Server
- Quest - DataCompare (no longer available)
- Red Gate - SQL Data Compare
- SqlDiffFramework
- TASC - SQL Delta
- TulsaSoft - SQL Data Examiner
- xSQL Software - xSQL DataCompare
DTS Comparison
- Red Gate - DTS Package Compare (no longer available)
Server Comparison
- Quest - ServerCompare (no longer available)
Free Tools
- SQL Effects CE Edition (no longer available)
If there are other products out there send an email to [email protected] and we will update this list.
Also, check out these tool pages:
Next Steps
- Next time you need to compare your database objects don't waste your time doing it manually. Purchase one of these products or download the free version and give it a try. Most if not all of these vendors offer free trial versions.
- Determine what needs to be compared and how frequently. Look at the different options that allow you to compare objects, data, dts packages and even servers.
- We provided the list of products, so take this list and find the product that is right for you.
About the author
This author pledges the content of this article is based on professional experience and not AI generated.
View all my tips
Article Last Updated: 2019-09-06