Skip to content

Data compare

Sometimes you need to compare data from two sources (tables.md) which have almost identical data with just few differences. There may be a plenty reasons to do so: quickly visualize all the differences and navigate through them by your sight, to copy differing rows or individual values or export them using Data Transfer.

Preparing the tool

  • You will need to choose one or two desired tables in the Database Navigator - it may be the tables from the same databases or from different databases or even from different RDBMS (e.g. PostgreSQL and MySQL).
  • Then choose DatabaseCompare/MigrateData Compare from the menu and the Data Compare Wizard will appear. Here you can preview selected tables or choose other ones. Then you can navigate to the second page.
  • After reaching the second page one may wonder about the purpose of it - don't worry, it's not that difficult: you should choose columns that will be used as a unique key during comparison (the amount of columns must be equal). If the keys chosen wrong, it may lead to invalid results. By default, if the table has unique key in it, it will be chosen automatically during the initial setup: Without unique keys the rows cannot be compared properly, since there's no way to distinguish between individual rows.
  • After reaching the last page, you can tweak limits (e.g. you only care about N first rows) and exclude categories of the resulting rows (e.g. you are not interested in modified rows). Also, you can press Save task button save configuration in a Task to use it later, or Schedule it, although it is not very useful right now, but we have plans to support exporting results as an SQL script and more.

Viewing the results

After finishing the wizard, you can press Start button to begin actual process of comparison - it may take some time depending on the databases you're comparing, the amount of data in them, and your network speed (*.md).

When the results are ready, DBeaver will play beep sound, and the editor will open:

Here you can examine the differences, swap the panels using Swap Containers button in the toolbar, or preview summary including statistics by using Show Summary button in the toolbar too. Everything you can do in the regular data editor is it possible to perform here - you can copy data or transfer it to other database, except you cannot modify values.

* - Please note that the actual preview is only available when Data Compare is launched through the wizard - otherwise only statistics will be written into the Task Log.

Under the hood

This section is under construction. It will include information about the engine's implementation details and more.