KS DB Merge Tools logo KS DB Merge Tools
Documentation
KS DB Merge Tools for MySQL logo for MySQL
and MariaDB
KS DB Merge Tools for Oracle logo
MssqlMerge logo
KS DB Merge Tools for PostgreSQL logo
KS DB Merge Tools for SQLite logo
AccdbMerge logo
KS DB Merge Tools for Cross-DBMS logo

Settings dialog

This dialog is used to setup application settings:

for MySQL, settings dialog

Each tab has self-descripting options. Here are some more details on the use cases when you may need to change these options:

  • Database Open settings tab:
    • Object types and filters group specified which object definitions will be loaded and compared. When you open a database, the application reads all chosen object definitions from the database and keeps them in memory. For a large database it takes some time. Or, maybe you're not interested in some changes at all. Using these settings you can specify which objects you need to load. So, by disabling some object types, you can speed up database open process and keep your focus only on objects you need. Please note that if you omit some object type, then this can prevent some further merge actions. For example, stored procedure (SP) can depend on some view. If you need to merge this SP to the other side, then you will have to merge that view first. But if you'll disable views loading, then you will not able to do this and on merge you'll get an error from the database server that referenced view does not exist in the target database
    • Project open/reload group allows you to change the behaviour you've chosen previously using Database reload dialog
  • Data diff settings tab configures default behavior for the Data diff tab:
    • Paging specifies default page size
    • String compare options defines the default state of ignore case and ignore leading and trailing whitespaces vertical toolbar action states
  • Text diff settings tab:
    • Text compare options defines the default text comparison rules and default text compare options like ignore case or whitespace. In addition it contains a list of custom text normalization rules (see below)
    • Text diff tab contains configuration of how many additional lines are shown for new/changed views:

      for MySQL, settings dialog text diff additional lines

  • Appearance settings tab:
    • Don't resize toolbar on application zoom allows to keep toolbar unchanged when you zoom application UI using and zoom toolbar actions
    • Max tab header width specifies the maximum width of tab in pixel for the main application tab control

Custom text normalization rules is something similar to Ignore case or Ignore whitespace options, but they allow to set up more sophisticated rules. For example, but default this list contains only one disabled rule:

  • Title: Function optional parentheses
  • Pattern: (?<fn>(CURRENT_DATE|CURRENT_TIME|CURRENT_TIMESTAMP|CURRENT_USER|LOCALTIME|LOCALTIMESTAMP))\(\)
  • Replacement: ${fn}
Let's suppose you have some stored procedure which calls CURRENT_TIMESTAMP function which can be defined with or without parentheses. And on the left side it is used as CURRENT_TIMESTAMP(), on the right side as CURRENT_TIMESTAMP - without parentheses. Functionally both calls do the same work and you may want to ignore such change. This can be achieved using this rule. Rules are based on .NET regex syntax. In our example Pattern defines fn regex variable which contains a function name without parentheses. And then the whole found string (with parentheses) is replaced with a variable value which has only the function name without parentheses. If this rule is enabled, then the application does not calculate missing parentheses text change. If that was the only change in the object definition, then the whole object is considered and counted as unchanged. In the Text diff tab line having such a change is highlighted in yellow (color of ignored change).

The following things needs to be taken into account when you use these rules:

  • These rules are applied for each separate line of each object definition. As a result they can significantly affect performance of objects loading and comparison. And since they are applied for each line - they can't be used for multi-line blocks of code, for example you can't ignore multiline comments using these rules
  • Order of object text processing: 1) whitespace removal ('Ignore whitespace' options), 2) skip empty lines, 3) custom normalization rules, by the order they are defined in Settings
  • Custom normalization is combined with 'Ignore case' option
  • Rule with invalid regex syntax in Pattern or Replacement will be ignored (however it will slow down objects processing as well)

Free version limitations:

  • The whole dialog is not available

Last updated: 2023-10-04