Viewing the SQL differences

Last modified: March 28, 2025

The lower part of the Comparison Results window displays differences in the creation SQL script for an object. A code that is different is displayed with a colored background.

Synchronize PostgreSQL databases - SQL differences window

Note

Click an arrow button Format script button if you want to collapse or expand the SQL comparer.

Viewing differences

If the object doesn’t exist, the code for its creation is displayed only on one side.

dbForge Studio - Code for object creation

This code will be added if you choose to synchronize databases.

SQL differences view toolbar

For the convenience of reviewing the SQL differences, dbForge Studio has a toolbar, allowing to customize the view.

Postgres Schema Diff - SQL differences view toolbar

  • Postgres sync databases - Word-wrap button The Word-wrap button breaks long lines for a more convenient view.
  • PostgreSQL synchronization - Show line numbers The Show line numbers button displays a column of sequential line numbers at the left side of the box with code. PostgreSQL sync two databases - Show lines
  • PostgreSQL sync tables between databases  - View white spaces button The View white spaces button displays whitespace characters as symbols. dbForge Studio - White spaces display
  • Postgres Schema Diff - View hex button The View hex button converts code to hex.
  • PostgreSQL synchronization - Sort button The Sort button sorts columns and constraints alphabetically.
  • If you want to format database object script, click Format script button
  • You can also open the text comparer in a detached window by clicking Text comparer in detached window. This button can be used to display DDL text differences on a second monitor if you use one.

Viewing the schema update script

To view the deployment script for the selected object, right-click it in the upper pane, and then click View Schema Update script.

dbForge Postgres Schema Diff - Viewing the schema update script

The schema update script will be displayed in the lower part of the Comparison Results window.

dbForge Studio Postgres - Update script

For your convenience, you can drag this window to a second monitor if you use one.