In a previous article, we discussed how to compare two Windows Azure SQL databases using ApexSQL Diff. In this article, we will explore how to compare data in two Windows SQL Server databases using ApexSQL Data Diff, a free tool for SQL data comparison and synchronization.
ApexSQL Data Diff allows you to compare SQL Server and SQL Azure databases without any difference. To get started, open the Project dialog and choose the destination and source databases, along with the Azure server. You can also filter and map objects using advanced features to include only specific objects in the comparison.
Once you have set up the comparison, you can begin comparing the objects. The Advanced tabs allow you to filter database objects using the Object filter feature. You can select or deselect objects that you want to compare. After the SQL data comparison is complete, the compared objects are displayed in an easily accessible results grid. Each compared object is shown with basic information and the number of differences in data between the two compared objects.
If you want to view the row level difference details, you can do so in the difference details pane. This allows you to synchronize specific rows if needed. The inline row filter option is available in the View tab, which allows you to filter compared objects based on different information such as object name, total rows, or schema.
The Grouping option allows you to group compared objects by object type, and multi-column sorting can be used to sort results by individual columns. Additionally, you can filter the results grid by different types such as different, identical, or incomparable objects.
To synchronize the detected differences, you can select specific objects from the result grid for synchronization. Alternatively, you can select all objects by using the check all option in the results group on the home tab. The Synchronization wizard will guide you through the synchronization process, which consists of three steps.
The first step is selecting the data source that will be changed, and you can choose the synchronization direction. The Synchronization wizard also provides an option to reverse the process if needed. The next step is selecting how to process the synchronization script. You can either create a synchronization script or synchronize the database directly. The script can be saved to a file or opened in an editor.
The final step is the Summary and Warnings, where you can preview the impact of the synchronization script. A detailed list of actions that will be taken during the synchronization process is shown, along with potential problems that might occur. The list of actions can be grouped by execution order, object, or action type.
Similar to ApexSQL Diff, ApexSQL Data Diff allows you to create comprehensive reports based on the obtained differences. You can choose from three export formats: HTML plain report, HTML report, and CSV data export. The HTML report format is interactive and user-friendly, allowing easy navigation and expand/collapse regions containing table/view information.
It’s important to note that ApexSQL Data Diff is free for all users of Windows Azure SQL Databases. For more information, you can visit their company blog Solution Center. If you’re looking for solutions to various SQL Server problems, be sure to explore their offerings.