Welcome to SQL Manager for PostgreSQL!

EMS SQL Manager for PostgreSQL is a high performance tool for PostgreSQL server administration and development. SQL Manager for PostgreSQL works with all PostgreSQL versions up to 16 and supports all of the latest PostgreSQL features including the FILLFACTOR parameter in tables and indexes, building indexes concurrently, ENUM data types, TSVECTOR, TSQUERY, XML and UUID types, arrays of composite types, operator classes in index keys, and others. It offers plenty of powerful tools for experienced users such as Database Designer, Visual Design Query and powerful BLOB viewer/editor to satisfy all their needs. SQL Manager has a new state-of-the-art graphical user interface with well-described wizard system, so clear in use that even a newbie will not be confused with it.

Visit our web-site for details: https://www.sqlmanager.net/

Key features

  • Full support of all PostgreSQL versions up to 16
  • Support of Unicode data
  • Support of collations
  • Support of database extensions
  • Support of view triggers
  • Support of unlogged tables
  • Rapid database management and navigation
  • Easy management of all PostgreSQL objects
  • Advanced data manipulation tools
  • Effective security management
  • Excellent visual and text tools for query building
  • Impressive data export and import capabilities
  • Database Designer to handle database structure in a few clicks
  • Easy-to-use wizards performing PostgreSQL server administrative tasks
  • Powerful tools to make your work with PostgreSQL as easy as it can be
  • Report designer with clear in use report construction wizard
  • Tools providing version control

Product information

Homepage: | https://www.sqlmanager.net/products/postgresql/manager
Support Ticket System: | https://www.sqlmanager.net/support
Register on-line: | https://www.sqlmanager.net/products/postgresql/manager/buy


What's new?

Version | Release date
SQL Manager for PostgreSQL 6.5.1 | February 16, 2024

What's new in SQL Manager for PostgreSQL?

1. Improved processing of local variables in procedures and SQL editor.

2. The list of arguments with default values is displayed correctly now.

3. Table view activates display all rows mode if all data is loaded.

4. GEOMETRY data is displayed as BLOB now.

5. Hint size is correct for non-standard scaling.

6. Timeout value increased for SSH connection.

7. GENERATED columns are processed right on column order change.

8. Version control updated for procedures and statistics.

9. Improvements in dark visual scheme.

10. Many other improvements and fixes.

See also:

Version history


System requirements

System requirements for SQL Manager for PostgreSQL

  • Microsoft Windows XP, Microsoft Windows Server 2003, Microsoft Windows Server 2008, Microsoft Windows Server 2008 R2, Microsoft Windows Server 2012, Microsoft Windows Server 2012 R2, Microsoft Windows Server 2016, Microsoft Windows Server 2019, Microsoft Windows Vista, Microsoft Windows 7, Microsoft Windows 8/8.1, Microsoft Windows 10, Microsoft Windows 11, Microsoft Windows 11 ARM
  • 512 Mb of RAM or more; 1024 Mb or more recommended
  • 200 Mb of available HD space for program installation
  • Possibility to connect to any local or remote PostgreSQL server
  • Supported PostgreSQL server versions: from 7.3 up to 16


Feature Matrix

The FREE Lite version of SQL Manager for PostgreSQL does not include all features of the Full version and has some limitations concerning the number of the databases that can be registered and the set of data manipulation and server maintenance tools. The detailed feature matrix is given below.

Note that when using the FREE Lite version of SQL Manager for PostgreSQL you can activate a 30-day period of fully-functional usage. After the period expires, you will be able to continue using the Lite version.

For more information on activating the Full version features see Full Mode activation.

 | Full version | Lite version
Full support of PostgreSQL up to the latest versions
Support of exclusion constrains | + | +
Support of the ‘when’ clause for triggers | + | +
Support of default values for function arguments | + | +
Support of functions returning table | + | +
Support of collations | + | +
Support of extensions | + | +
Support of view triggers | + | +
Support of unlogged tables | + | +
Support of materialized views | + | +
Support of recursive views | + | +
Support of event triggers | + | +
Support of UTF8 data | + | +
New state-of-the-art graphical user interface
Dark visual schema support | + | +
New well-described Wizard System | + | +
Improved database explorer for easy managing of all PostgreSQL objects | + | +
New Windows Toolbar to switch between windows easily, like in Windows Task Bar | + | +
Navigation bars with hot actions in most of the windows | + | +
Ability to save all program settings | + | +
Customizable toolbars for all program windows | + | +
Fully customizable program interface | + | +
Flexible visual options | + | +
Localizable program interface | + | +
Rapid database management and navigation
Multiple host/database connections | + | +
SSL connections support | + | +
Registering selected databases to work with | + | +
Projects to work with the selected database objects only | + | +
Access to PostgreSQL Server through HTTP protocol | + | +
Connecting via local port forwarding through the SSH tunnel | + | -
Multiple user-defined tabs for any tree node to access it in one-click | + | +
Working with multiple selected objects at a time | + | +
Grouping/ungrouping registered databases by host name | + | +
Easy management of all PostgreSQL objects
Creating/dropping databases and schemas | + | +
Managing tables and all their subobjects: fields, indices, triggers, rules, checks and foreign keys | + | +
Managing views, functions, procedures, sequences, collations | + | +
Managing types, aggregates, operators, languages | + | +
Managing table/view rules | + | +
Duplicating all database objects | + | +
Renaming all database objects | + | +
Powerful PL/pgSQL function debugger | + | -
Viewing dependencies between database objects | + | +
Advanced data manipulation tools
Powerful BLOB viewer/editor with several modes of viewing BLOB data | + | -
Plenty of useful tools such as data grouping, fast searching and filtering | + | +
Master-detail view to work with two linked tables at the same time | + | -
Table and card views to see data the way you like | + | -
Ability to copy and paste selected records | + | -
Ability to create diagrams based on queries | + | -
Exporting data to SQL script as INSERT statement | + | -
Effective security management
Powerful user and group manager for administering users and privileges | + | +
Grant manager displaying all database object grants in the form of a grid | + | +
Viewing and changing object permissions to database roles in object editors | + | +
Excellent visual and text tools for query building
Visual query designer allowing you to build complicated queries without any knowledge of SQL syntax | + | -
Multiple SQL editors with code completion, syntax highlight and code folding | + | +
Large script execution (Execute cript editor) | + | +
Ability to view query plan as a diagram | + | -
SQL Formatter (available from Query data editor) | + | -
Favorite Queries (Save and use your frequently used queries easily) | + | +
Report designer with a clear in use report construction wizard
Create Report Wizard allows you to create simple reports in a few clicks | + | -
Managing reports the same way as if they were database objects: accessing reports directly through the DB Explorer tree | + | -
Impressive data export and import capabilities
Exporting data to most popular formats: MS Excel, MS Word, MS Access, HTML, PDF, TXT, CSV, DBF, XML, ODF, etc. | + | -
Importing data from MS Excel, MS Access, DBF, XML, ODF, TXT and CSV | + | -
Wizards for copying data from/to file on server | + | -
Copying metadata and data from one database to another as a whole or partially | + | -
Powerful visual Database Designer
Two diagram notations (IDEF1x and IE) | + | -
Useful diagram navigation tool | + | -
Reverse engineering | + | -
Several pages in one diagram to divide diagram into different subject areas | + | -
Ability to create, edit and drop tables and table fields, set links between tables visually | + | -
Ability to add comments to diagram | + | -
Saving as image or printing database diagram | + | -
A lot of visual customization options | + | -
Database change management
Support of Concurrent Versions System (CVS), Subversion (SVN), Visual SourceSafe (VSS), Team Foundation Server (TFS) | + | -
Ability to manage database related development processes | + | -
Ability to roll back database structure to any version in the past | + | -
Ability to create database branches | + | -
Ability to create tag/label to save the current database state | + | -
Ability to get a script of differences between two database states and test it on a created test database | + | -
Ability to store any SQL scripts in version control system repository of a database | + | -
Ability to browse history of database and/or object changes | + | -
Easy-to-use wizards performing PostgreSQL maintenance tasks
Analyzing tables | + | -
Vacuuming tables | + | -
Clustering tables | + | -
Reindexing tables | + | -
Server Log Viewer | + | -
Backup Database wizard | + | +
Restore Database wizard | + | +
Other useful tools to make your work with PostgreSQL server as easy as it can be
Database statistics module to view various statistic information on database objects | + | -
Extracting metadata into text files or SQL script editor | + | +
Powerful print metadata module for creating customizable metadata reports | + | -
HTML report wizard to create a detailed HTML report about your database quickly | + | -
Report designer for building powerful reports visually | + | -
Wizard to download and upload files from/to PostgreSQL server | + | -
Compare Databases wizard | + | -
Database Extensions | + | +
SQL Monitor | + | +
Search in metadata tool | + | -
...and other useful features
Keyboard templates | + | +
To-do list | + | +
External tool manager | + | +


Installation

SQL Manager for PostgreSQL
  • Index
  • « Prev
  • Next »

Installation of SQL Manager for PostgreSQL

If you are installing SQL Manager for PostgreSQL for the first time on your PC:

  • download the SQL Manager for PostgreSQL distribution package from the download page available at our site;
  • unzip the downloaded file to any local directory, e.g. C:\unzipped;
  • run PgManagerFull.exe (Full version) or PgManagerLite.exe (Lite version) from the local directory and follow the instructions of the installation wizard;
  • after the installation process is complete, find the SQL Manager shortcut in the corresponding group of Windows Start menu.

If you want to update an installed copy of SQL Manager for PostgreSQL you need to use SQL Direct.

Also you can use the full distribution package to upgrade your current version of SQL Manager for PostgreSQL. In this case, you should repeat the steps you have made for the first-time installation.

See also:

SQL Manager FAQ


Registration

All purchases are provided by Digital River registration service. The Digital River order process is protected via a secure connection and makes on-line ordering by credit/debit card quick and safe.

Digital River is a global e-commerce provider for software and shareware sales via the Internet. It accepts payments in US Dollars, Euros, Pounds Sterling, Japanese Yen, Australian Dollars, Canadian Dollars or Swiss Franks by Credit Card (Visa, MasterCard/EuroCard, American Express, Diners Club), Bank/Wire Transfer, Check or Cash.

If you want to review your order information, or you have questions about ordering or payments please visit our Customer Care Center, provided by Digital River.

Please note that all of our products are delivered via ESD (Electronic Software Delivery) only. After purchase you will be able to immediately download the registration keys or passwords. Also you will receive a copy of registration keys or passwords by email. Please make sure to enter a valid email address in your order. If you have not received the keys within 2 hours, please, contact us at sales@sqlmanager.net.

Product distribution | MyCommerce/Digital River
SQL Manager for PostgreSQL (Business license) + 1-Year Maintenance* | Register Now!
SQL Manager for PostgreSQL (Business license) + 2-Year Maintenance*
SQL Manager for PostgreSQL (Business license) + 3-Year Maintenance*
SQL Manager for PostgreSQL (Non-commercial license) + 1-Year Maintenance*
SQL Manager for PostgreSQL (Non-commercial license) + 2-Year Maintenance*
SQL Manager for PostgreSQL (Non-commercial license) + 3-Year Maintenance*
SQL Manager for PostgreSQL (Trial version) | Download Now!
SQL Manager for PostgreSQL Lite | Download Now!

*EMS Maintenance Program provides the following benefits:

  • Free software bug fixes, enhancements, updates and upgrades during the maintenance period
  • Free unlimited communications with technical staff for the purpose of reporting Software failures
  • Free reasonable number of communications for the purpose of consultation on operational aspects of the software

After your maintenance expires you will not be able to update your software or get technical support. To protect your investments and have your software up-to-date, you need to renew your maintenance.

You can easily reinitiate/renew your maintenance with our on-line, speed-through Maintenance Reinstatement/Renewal Interface. After reinitiating/renewal you will receive a confirmation e-mail with all the necessary information.

See also:

How to register SQL Manager


How to register SQL Manager

If you have not registered your copy of SQL Manager for PostgreSQL yet, you can do it by pressing the Register Now button and entering your registration information in the Register SQL Manager for PostgreSQL dialog.

Welcome to SQL Manager - About

To register your newly purchased copy of EMS SQL Manager for PostgreSQL, perform the following steps:

  • receive the notification letter from Digital River with the registration info;
  • enter the Registration Name and the Registration Key from this letter;
  • make sure that the registration process has been completed successfully – check the registration information in the About SQL Manager for PostgreSQL dialog (use the Help | About menu item to open this dialog).

Welcome to SQL Manager - Register product

See also:

Registration


Version history

Product name | Version | Release date
SQL Manager for PostgreSQL | Version 6.5 | December 21, 2023
SQL Manager for PostgreSQL | Version 6.4.3 | October 10, 2023
SQL Manager for PostgreSQL | Version 6.4.2 | March 27, 2023
SQL Manager for PostgreSQL | Version 6.4.1 | November 11, 2022
SQL Manager for PostgreSQL | Version 6.4 | October 18, 2022
SQL Manager for PostgreSQL | Version 6.3.2 | April 3, 2022
SQL Manager for PostgreSQL | Version 6.3.1 | July 23, 2021
SQL Manager for PostgreSQL | Version 6.3 | April 7, 2021
SQL Manager for PostgreSQL | Version 6.2 | December 21, 2020
SQL Manager for PostgreSQL | Version 6.1.1 | May 13, 2020
SQL Manager for PostgreSQL | Version 6.1 | January 27, 2020
SQL Manager for PostgreSQL | Version 6.0.1 | December 6, 2019
SQL Manager for PostgreSQL | Version 6.0 | November 1, 2019
SQL Manager for PostgreSQL | Version 5.9.5 | March 18, 2019
SQL Manager for PostgreSQL | Version 5.9.4 | July 27, 2018
SQL Manager for PostgreSQL | Version 5.9.3 | May 29, 2018
SQL Manager for PostgreSQL | Version 5.9.2 | December 08, 2017
SQL Manager for PostgreSQL | Version 5.9.1 | April 27, 2017
SQL Manager for PostgreSQL | Version 5.9 | March 9, 2017
SQL Manager for PostgreSQL | Version 5.8.1 | December 16, 2016
SQL Manager for PostgreSQL | Version 5.8 | October 19, 2016
SQL Manager for PostgreSQL | Version 5.7.1 | June 29, 2016
SQL Manager for PostgreSQL | Version 5.7.0 | March 25, 2016
SQL Manager for PostgreSQL | Version 5.6.2 | December 18, 2015
SQL Manager for PostgreSQL | Version 5.6.1 | November 18, 2015
SQL Manager for PostgreSQL | Version 5.6.0 | September 14, 2015
SQL Manager for PostgreSQL | Version 5.5.0 | October 6, 2014
SQL Manager for PostgreSQL | Version 5.4.0.1 | October 14, 2013
SQL Manager for PostgreSQL | Version 5.3.0.1 | April 8, 2013
SQL Manager for PostgreSQL | Version 5.2.0.1 | November 15, 2012
SQL Manager for PostgreSQL | Version 5.1.0.1 | December 05, 2011
SQL Manager 2011 for PostgreSQL | Version 5.0.0.1 | May 17, 2011
SQL Manager 2010 for PostgreSQL | Version 4.8.0.1 | November 15, 2010
SQL Manager 2010 for PostgreSQL | Version 4.7.0.1 | February 15, 2010
SQL Manager 2010 for PostgreSQL | Version 4.6.0.1 | September 9, 2009
SQL Manager 2007 for PostgreSQL | Version 4.5.0.1 | December 10, 2008
SQL Manager 2007 for PostgreSQL | Version 4.4.0.1 | July 18, 2008
SQL Manager 2007 for PostgreSQL | Version 4.3.0.1 | February 4, 2008
SQL Manager 2007 for PostgreSQL | Version 4.2.0.1 | December 13, 2007
SQL Manager 2007 for PostgreSQL | Version 4.1.0.1 | June 20, 2007
SQL Manager 2007 for PostgreSQL | Version 4.0.0.1 | May 17, 2007
SQL Manager 2005 for PostgreSQL | Version 3.8.0.1 | December 14, 2006
SQL Manager 2005 for PostgreSQL | Version 3.7.0.1 | October 9, 2006
SQL Manager 2005 for PostgreSQL | Version 3.6.0.1 | May 31, 2006
SQL Manager 2005 for PostgreSQL | Version 3.5.0.1 | April 3, 2006
SQL Manager 2005 for PostgreSQL | Version 3.4.0.1 | February 7, 2006
SQL Manager 2005 for PostgreSQL | Version 3.3.0.1 | November 21, 2005
PostgreSQL Manager | Version 3.2.0.1 | August 29, 2005
PostgreSQL Manager | Version 3.1.5.1 | July 5, 2005
PostgreSQL Manager | Version 3.1.0.1 | June 14, 2005
PostgreSQL Manager | Version 3.0.0.1 | June 1, 2005
PostgreSQL Manager | Version 2.8.0.1 | January 24, 2005
PostgreSQL Manager | Version 2.7.0.1 | December 1, 2004
PostgreSQL Manager | Version 1.4.0.1 (Linux) | November 15, 2004
PostgreSQL Manager | Version 2.6.0.1 | October 7, 2004
PostgreSQL Manager | Version 2.5.0.1 | June 30, 2004
PostgreSQL Manager | Version 2.4.0.1 | April 28, 2004
PostgreSQL Manager | Version 2.3.0.1 | March 22, 2004
PostgreSQL Manager | Version 2.2.0.1 | February 16, 2004
PostgreSQL Manager | Version 1.3.0.1 (Linux) | February 9, 2004
PostgreSQL Manager | Version 2.1.0.1 | January 12, 2004
PostgreSQL Manager | Version 2.0.0.1 | December 10, 2003
PostgreSQL Manager | Version 1.8.0.1 | September 3, 2003
PostgreSQL Manager | Version 1.2.0.1 (Linux) | July 8, 2003
PostgreSQL Manager | Version 1.7.0.1 | June 18, 2003
PostgreSQL Manager | Version 1.1.0.1 (Linux) | May 22, 2003
PostgreSQL Manager | Version 1.6.0.1 | May 12, 2003
PostgreSQL Manager | Version 1.0.0.1 (Linux) | April 17, 2003
PostgreSQL Manager | Version 1.5.0.1 | April 9, 2003
PostgreSQL Manager | Version 1.4.0.1 | March 12, 2003
PostgreSQL Manager | Version 1.3.0.1 | February 21, 2003
PostgreSQL Manager | Version 1.2.0.1 | January 16, 2003
PostgreSQL Manager | Version 1.1.0.1 | December 9, 2002
PostgreSQL Manager | Version 1.0.0.1 | December 2, 2002
PostgreSQL Manager | First public release | November 4, 2002

Version 6.5

1. SQL Manager x64 for PostgreSQL released.

2. Service templates are now saved in UTF8.

3. New authentication methods added.

4. Support of STATISTICS objects added.

5. NULLS NOT DISTINCT option added to indicies editor.

6. SET COMPRESSION option added for table columns.

7. Improvements in Service Status viewer.

8. TIMESTAMP and TIMESTAMPTZ data can be optionally displayed as string.

9. Multiple rows of tabs is now supported in Query Data.

10. Multiple Cursor datasets are now displayed correctly in Function results.

11. PDF data can be viewed from BLOB editor now.

12. Many other improvements and fixes.

Version 6.4.3

1. The issue when opening Export Data Wizard has been resolved.

2. The Owner was not displayed for Aggregates. Fixed now.

3. Types from pgcatalog could not be selected for state type aggregates. Fixed now.

4. The error occured in Enum types editor on editing values. Fixed now.

5. The "Control 'Preview' has no parent window" error resolved in Print data editor for data grid.

6. Details of the operations were not displayed on clicking the elements in Query Plan. Fixed now.

7. In some cases the error occured when executing queries with parameters. Fixed now.

8. Other minor fixes and improvements.

Version 6.4.2

1. Improvements in PostgreSQL 15 support.

2. Improved support of dark schema for interface.

3. Support for LANGUAGE SQL body for functions.

4. FK links can be optionally hidden in Design Query editor now.

5. Templates for backup and restore are now saved in Unicode format.

6. Improved performance in Server Log Viewer.

7. Export of images as SQL Script now works correctly.

8. Filter window for data grid is resizable now.

9. Resizing of Database Designer editor works better now.

10. The list of visible columns was reset on switching to Card view. Fixed now.

11. Other improvements and fixes.

Version 6.4.1

1. Support for PostgreSQL 15 added.

2. Fixed issue with client sorting of NUMERIC data.

3. Sequence values are added correctly for GENERATED BY DEFAULT columns.

4. 'Automatically open last diagram file' option didn't work in Database designer. Fixed now.

5. Improvements in code highlighting in SQL editors done.

6. The charset errors in BLOB editor fixed.

7. Other improvements and bugfixes.

Version 6.4

1. Added displaying of field types in Data tab.

2. Support for index storage options implemented.

3. Improvements in server log viewer implemented.

4. DB explorer objects can be collapsed and expanded at once now.

5. Indices for views added to Version control.

6. Support for Ed25519 Putty private keys implemented.

7. Support for Windows 11 ARM implemented.

8. Filters implemented for ENUM data type.

9. Better processing of large NUMERIC data in Data editor.

10. Next\Previous search is now more precious in the DB tree.

11. Performance improved for HTTP tunnelling.

12. Better formatting of JSON data.

13. Hot keys added for use of markers in script editor.

14. Fixes of displaying procedure privileges done.

15. Processing of milliseconds for TIMESTAMP data improved.

16. Table fields added to autocompletion for INSERT INTO operator.

17. The error occurred on adding data with autogenerated values. Fixed now.

18. The error occurred on editing comments for materialized views. Fixed now.

19. Code highlighting improved in script editor.

20. The error fixed in Procedure debugger on using search_path with specific symbols.

21. Toolbars reset didn't work in some cases. Fixed now.

22. Favorite queries are now saved when using Save settings wizard.

23. DB Comparer. Sequences are now extracted without OWNER.

24. Many other improvements and fixes.

Version 6.3.2

1. Show OWNER on DDL tab option added.

2. Sorting implemented for text BLOB fields.

3. Hosts an databases are sorted by name in drop-down menus.

4. Data type added to the field name in the code completion list.

5. Data format settings are now available for export into XLSX file.

6. Quotation mark was duplicated on export in some cases. Fixed now.

7. Commands in one line are now executed properly.

8. Log tab is activated on error only now.

9. The error of displaying Bit varying data fixed.

10. Unnecessary quotation marks added to parameter history in procedures. Fixed now.

11. SSL settings are now saved correctly for databases.

12. Issue with using Space in passwords resolved.

13. Many other fixes and improvements.

Version 6.3.1

1. The GENERATED option added on fields creating.

2. Fields are formatted more accurately in INSERT INTO statements.

3. Minor errors fixed in parameters history of functions.

4. The Out of range error on the Dependencies tab is fixed.

5. Minor improvements in displaying dark color schema.

6. Other fixes and improvements.

Version 6.3

1. Parameters history is now loaded correctly on changing SQL text.

2. Databases are now focused on launching the program.

3. The list of events has been updated for EVENT TRIGGER.

4. The error occurred in the debugger with many parameters used. Fixed now.

5. TIMESTAMPTZ data was imported incorrectly in some cases. Fixed now.

6. Decimal numbers are now rounded correctly.

7. Filtering is not truncated on switching between table tabs now.

8. New Query data button is added to the toolbar.

9. The error occurred on using aliases in Query Designer. Fixed now.

10. Other minor improvements and fixes.

Version 6.2

1. The libraries for connection via SSH have been updated.

2. Valid processing of extensions added for PostgreSQL 13.

3. No more freezing occurs on adding a new user in the User manager.

4. The INCLUDE parameter is now displayed correctly for indices.

5. The error occured on running queries with aggregate functions. Fixed now.

6. Databases in the Save settings wizard are now sorted by name.

7. You can switch to an already opened Query editor with F12 now.

8. Print Data preview was generated on opening the Data tab. Fixed now.

9. The file is now opened instead of just copying its content into Script Editor.

10. Other improvements and bug-fixes.

Version 6.1.1

1. Improved work with Amazon RedShift.

2. COPY command is now supported in script editor.

3. Quick access to Search in Metadata from object tree added.

4. NULL values were not assigned correctly in the debugger. Fixed now.

5. Search path command was not applied for query plan. Fixed now.

6. Path to the last opened file is now saved in script editor.

7. Work with TIMESTAMPTZ data type improved.

8. The warning appears if the file is changed outside of the script editor.

9. The error of moving extension to another scheme fixed.

10. Host aliases are now displayed correctly in object editors.

11. Current values for sequences were truncated on reordering table fields in some cases. Fixed now.

12. Other fixes and improvements.

Version 6.1

1. Multiple Query data editors are now allowed for the same database.

2. Multiple Search in metadata windows can be opened now.

3. Improvements in find and replace text dialog.

4. Imporved performance of Debug with extension.

5. Extension functions and procedures are no longer displayed in DB Explorer, if system objects are disabled.

6. Fix of defining BOOLEAN parameters in the debugger.

7. Microseconds are always displayed for timestamptz data type now.

8. Many other fixes and improvements.

Version 6.0.1

1. Font for autocompletion list is changed with editor font now.

2. Data refresh in materialized views with transactions enabled is performed without Timeout error now.

3. Fixes in Find text and Search in metadata.

4. Disappearing of the main menu in localized interface fixed.

5. Close all windows action now requires confirmation.

6. Toolbars on the main form can be moved without any restrictions now.

7. Editor content is saved correctly on renaming server alias.

8. Other minor fixes and improvements.

Version 6.0

1. Support of dark visual scheme added.

2. The new look with updated icons.

3. Added support for PostgreSQL 12.0.

4. Support of Unicode added for object names.

5. Improved support of high-DPI monitors and large-scale fonts.

6. Editor tabs can be now highlighted with color specified for the database.

7. Support for server aliases implemented.

8. JSON tab added for viewing data.

9. Description support added for tablespaces.

10. "Refresh concurrently" command added for materialized views.

11. Trailing spaces are not automatically trimmed for CHAR fields now.

12. Fixes and improvements of auto completion feature in query editor.

13. Custom formatting can now be applied to timestamptz data.

14. Many other bug-fixes.

15. Other improvements of interface and usability.

Version 5.9.5

1. Procedures are now supported.

2. Added support for 11.1 version backup.

3. PARALLEL option added to functions.

4. Storage method is now displayed for fields.

5. Improved syntax check in functions.

6. Type name was not displayed for some user data types in functions. Fixed now.

7. Minor fixes in the Save settings wizard.

8. Nested multiline comments are now recognized correctly.

9. Query plan didn’t return any data if no space was set after EXPLAIN. Fixed now.

10. Transaction was sometimes aborted on importing data if database and client charset was different. Fixed now.

11. Statements for OWNER change in materialized view were generated incorrectly. Fixed now.

12. BIT VARYING data with unlimited size is now displayed correctly in data frame.

13. Many other fixes and improvements.

Version 5.9.4

1. Support for backup and restore of 10.4 и 11.0 server versions has been added.

2. Compare databases. Support for partitioned tables implemented.

3. Compare databases. NEXT_VALUE is not synchronized for sequences by default.

4. Owner info is now displayed on the DDL tab.

5. REFERENCING option is now supported in triggers.

6. Some errors in the debugger have been fixed.

7. Minor improvements in Query Data highlighting.

8. Many other improvements and bug-fixes.

Version 5.9.3

1. Added GENERATED AS IDENTITY property for fields.

2. Import failed in "Update or Insert" mode, if all columns were selected as keys. Fixed now.

4. Fixes and improvements in the Debugger.

5. User list is now exported to the correct folder.

6. Privilegies are restored correctly on recreating the field now.

7. Support of partition options has been implmented in the Extract database wizard.

8. Cast operator (::) can be used with parameter symbol (:) correctly.

9. Text with quotes and backslashes is imported correctly now.

10. Functions with domain-based parameters were not displayed in Search metadata results. Fixed now.

11. Export of TO-DO list has been implemented.

12. Trailing spaces were trimmed on copying records in the grid. Fixed now.

13. Many other improvements and bugfixes.

Version 5.9.2

1. Support for PostgreSQL 10 has been added.

2. Added support for partitioned tables.

3. The Debugger has been considerably improved.

4. Debugging with pldbgapi extension is possible now.

5. Improvements in Compare databases wizard.

6. Function editor windows with long names are restored correctly now.

7. In some cases passwords from pgpass.conf were not used. Fixed now.

8. Commit and Rollback buttons are not shown now if no changes were made.

9. Query Data. Execution of the query will continue on error, if "Show result for each query" is enabled.

10. Form view. NOT NULL attribute was not available for BOOLEAN type. Fixed now.

11. Function editor. The shortcut for debugging changed to Ctrl+D now.

12. Many other fixes and improvements.

Version 5.9.1

1. New options added in the Policy Editor.

2. Support of WITH RECURSIVE syntax in the Debugger added.

3. The error occurred on debugging procedures with the same name for input parameters and table field. Fixed now.

4. Unicode symbols were not imported correctly in Batch insert mode. Fixed now.

5. Commit transaction button was not displayed in some cases. Fixed now.

6. The comments are saved correctly now in Database Designer.

7. Comments for indices are now duplicated correctly to a new schema.

8. Many other bugfixes and improvements.

Version 5.9

1. Support for SSL certificates implemented.

2. Support for constraint triggers added.

3. Working with data in grid is performed with Savepoints now.

4. Search path can be set in the debugger now.

5. The hang of the program on editing scripts has been eliminated.

6. Text tab is opened by default for text types in BLOB editor now.

7. Raise notices used to display at the end of the execution in Query Data. Fixed now.

8. Script for indices was not generated on materialized view modification. Fixed now.

9. Hot keys added for search results in DB Explorer.

10. Many other improvements and bugfixes.

Version 5.8.1

  1. Fix of backup error on 9.6 version of PostgreSQL.
  2. There was an error on exporting some query results. Fixed now.
  3. The result dataset of the query was not editable if the comments preceded the query text. Fixed now.
  4. NUMERIC values were incorrectly exported into SQL. Fixed now.
  5. SSH connection was not established in some cases with OpenSSH private key used. Fixed now.
  6. Lots of other improvements and bugfixes.

Version 5.8

  1. Support for PostgreSQL 9.6 has been added.
  2. Support for DEFERRABLE/NOT DEFERRABLE and INITIALLY DEFERRED/INITIALLY IMMEDIATE options for Primary and Unique keys.
  3. Support of PHP 7.x in HTTP-tunneling module.
  4. Function debugger. Extended support for RAISE and EXCEPTION statements; processing of replace directives added.
  5. Some errors of Formatter have been fixed.
  6. Toolbar settings are saved correctly now.
  7. INTERVAL dimension was displayed incorrectly. Fixed now.
  8. Memory errors in Grant Manager have been fixed.
  9. Export of Unicode data from BLOB fields has been fixed.
  10. Lots of other improvements and bugfixes.

Version 5.7.1

  1. Added support of the latest versions of OpenSSH.
  2. Authentication error occurred when SSH private key was used. Fixed now.
  3. The 'Access Violation' error occurred when on index creation localization was turned on. Fixed now.
  4. The default directories were set incorrectly when a new host was registered. Fixed now.
  5. Other improvements and bug-fixes.

Version 5.7.0

  1. PostgreSQL 9.5 support.
  2. Support of 'REPLICATION' groups option.
  3. Support of 'BRIN' method for table indexes.
  4. The ability to change the 'LOGGED' table option added.
  5. Support of inheritance for external tables.
  6. Support of table policies.
  7. Indexes for materialized views have been implemented.
  8. The errors on managing objects containing quotes in their names have been fixed.
  9. Some memory errors have been fixed.
  10. Other improvements and bug-fixes.

Version 5.6.2

  1. Work with memory has been improved.
  2. The error on closing BLOB Editor has been fixed.
  3. Opening of SQL Script from the command line is performed in the same program instance now.
  4. Autocomplete for big functions and SQL queries has been improved.
  5. Use of triggers for more than 64 fields is possible now.
  6. The errors occured in Group Manager if there was no "Can create roles" permission set. Fixed now.
  7. Export Data. Export format is saved for the next session now.
  8. The connection error messages have been improved.
  9. Some objects with quotes were incorrectly processes in Function Editor. Fixed now.
  10. Export Data. Default tab name has been changed for export to MS Excel
  11. Export Data. Export formats are renamed to comply with MS Office standards.
  12. Lots of other improvements and bug-fixes.

Version 5.6.1

  1. Processing of REFCURSOR values at the Data tab has been improved.
  2. Now managing groups is possible for non-Admin users having the appropriate permissions.
  3. Improved handling of the functions having "_" character in the name.
  4. The order of objects generated by Extract Database tool was incorrect. Fixed now.
  5. There were some issues starting the application on specific national Windows versions. Fixed now.
  6. Several memory issues have been fixed.
  7. Fixes for Excel and CSV formats in Import Data wizard.
  8. The errors on opening Server Status tool have been fixed.
  9. Descriptions were lost on changing field order. Fixed now.
  10. Script fot duplicating UNLOGGED tables was generated incorrectly. Fixed now.
  11. Lots of other bug-fixes.

Version 5.6.0

  1. Support of foreign data wrappers, foreign servers and foreign tables is added.
  2. Dependency Tree.
  • Added the possibility to move the tree within the display area by holding the left mouse button.
  • Changed the drawing of selected object and recursive objects for better distinction.
  • Added different display modes of dependency tree: to show all objects, to show objects depending on selected object, or only objects selected object depends on.
  • Selected object is placed to the display area automatically now when the dependency tree is too large.
  3. Table Editor. Data tab. The possibility to create automatically the detail data levels for tables connected with the given one by means of foreign keys is added.
  4. Windows panel.
  • Added the ability to move tabs of open windows with a mouse.
  • Now it is possible to close the windows with the scroll button.
  5. DB Explorer. Favorite queries and scripts can be added into 'Favorite Objects' folders.
  6. Environment Options.
  • The possibility to set the Parameter character for SQL queries (Tools tab).
  • It is possible to set the font for data grid separately.
  • DB Explorer. Added the 'Start-with search' option for searching objects.
  • DB Explorer. Added the 'Auto expand navigation pane' option.
  • Added the possibility to switch off the 'Restore desktop on connection' option for the databases having the 'Refresh objects on connection' option off.
  • Added the possibility to specify which database should be selected for a newly opened editor or tool: the database selected in DB Explorer or the one from the currently focused editor.
  • Design Query | Color Palette options. Added the possibility to set colors for active and inactive table caption text (the 'Windows style of tables' should be turned off).
  • Global Shortcuts. Added shortcuts for the debugger.
  7. Query Data. Now after executing the 'BEGIN' SQL-statement the 'Commit' and 'Rollback' buttons become available in the toolbar and the navigation bar, even if using transactions is not turned on in the 'Database Registration Info' dialog. Also the confirmation of transaction ending will appear on closing the form (if it is not disabled on the 'Confirmations' tab of the 'Environment Options' dialog).
  8. Data Grid. Now it has become possible to select several cells and copy them to clipboard. To do this it is necessary to switch on the 'Cell selection' and 'Row/cell multi-selection' options on Grid tab of the Environment Options dialog.
  9. Duplicate Object wizard. Now when duplicating a table to another database the data copy statements are not added to the main table script, but are executed separately. This requires less memory.
  10. SQL editor.
  • Quick Code. It is possible to choose item in the Code Completion list with the 'Space' or with the 'TAB' key (optional).
  • The possibility to select the query text and choose the 'Export Data' dialog with the help of corresponding context menu item.
  11. Export Data as SQL Script, Extract Database. Now the last chosen charset is selected in the 'Script destination' | 'File charset' field by default.
  12. Query Data. Query Plan.
  • Now the query execution plan can be displayed graphically if the 'Verbose' option is used.
  • The 'Operation info' is implemented as a separated text field now.
  13. Visual Options. Added the possibility to set Slants Kind property value for page controls.
  14. Some forms were sized incorrectly when the 'Medium' size was chosen for the 'Control Panel\Display | Size of All Items' Windows option. Fixed now.
  15. SQL Monitor. Now the log can be executed as usual SQL-script: all the additional information is formatted as SQL-comments.
  16. Lots of other improvements and bug-fixes.

Version 5.5.0

  1. Added support of new PostgreSQL 9.4 features:
    • Support of JSONB data type
    • Support of changing foreign key deferability parameters without recreating the key
    • Support of moving all objects from one tablespace to another
  2. Extract Database. Now the result script is correctly organized according to objects dependencies.
  3. Backup Database. Now it is possible to add the current date and time to the result dump file name.
  4. Change Management. Added support of the Slik Subversion 1.8.x client (SQL Manager works with 32-bit client version only).
  5. Query Data. Code Completion. The PostgreSQL keywords is updated considering the last server versions.
  6. Table Editor. Reorder Fields. Now the trigger is created after the data insert in the change script.
  7. Query Data. Now if the "Don’t save queries automatically for the next session" option is enabled, the user is warned that the changes are not saved automatically on closing the Query Data tab.
  8. Change Management. SVN.
  • If the HTTPS-certificate is not valid the user is requested on performing the operation whether to ignore the validation mistake or abort the operation.
  • On entering non-latin characters in a commit comment to the Version Control System the "Cannot write database history record" error appeared. Fixed now.
  9. Query Data. Query Plan. Now the numerical values are right-aligned and are splitted by orders.
  10. DB Explorer. Now the Search field is not emptied when the search is finished.
  11. Backup Database. The long operation log was cut at the end. Fixed now.
  12. Function DDL. Illegal characters for unquoted identifiers were quoted incorrectly in parameters names. Fixed now.
  13. Data Export. When exporting to the DBF file values of integer fields appeared in the result file with a thousand separator. Fixed now.
  14. The wrong script generated on renaming fields of a view in a non-default schema. Fixed now.
  15. Sometimes error occurred on changing a field type to smallserial. Fixed now.
  16. Function Debugger. It was impossible to change the variable value of the time type.
  17. Large number of other improvements and bug fixes.

Version 5.4.0.1

  1. Added support of new PostgreSQL 9.3 features:
  • Support of materialized views.
  • Support of recursive views.
  • Support of event triggers.
  2. Query Data. Code Completion improvements:
  • The list of columns of function and subquery aliases is shown now.
  • The list of table / subquery columns of current SELECT query is now shown at Code Completion even without indicating its alias.
  • Context sensitive elements: aliases of the current SQL query, local variables, table / subquery columns now are arranged at Code Completion at the top of the list.
  3. Function Debugger. When the debugger is launched for the first time, the same parameter values are set as the ones for function execution.
  4. Such types as event_trigger and json are added to the list of standard types.
  5. Table, View Editors. Rename command is now available for subobjects.
  6. Operator Editor. Name field now allows entering admissible characters for operator name only.
  7. Several errors are fixed in Function Debugger:
  • If the last string of the function body was a comment, syntax error occurred. Fixed now.
  • If the function to debug contained operations with oid-type values, "can't read the blob" error occurred. Fixed now.
  • If a too large number was set as a bigint-type parameter, its precision was lost. Fixed now.
  8. The main menu command Help | PostgreSQL Reference worked incorrectly. Fixed now.
  9. Function Editor.
  • In some cases copy/paste data from the clipboard shortcuts Ctrl+Ins and Shift+Ins stopped working. Fixed now.
  • At times when exporting results of the function returning rowset, access violation error occurred. Fixed now.
  10. Find/Replace dialogs. Keyboard accelerators of some input fields were duplicated. Fixed now.
  11. Data Export wizard. When using Skip records option, it indicated that export had been carried out with errors, while in fact the operation had been successful. Fixed now.
  12. Lots of other improvements and bug-fixes.

Version 5.3.0.1

  1. Now when modifying an object, a window is marked with an asterisk (*) in the window title. The same is for the files opened in SQL Script form, Database Designer diagrams, etc.
  2. Database Registration Info dialog. Added the possibility to set PostgreSQL parameter values ​​for a session.
  3. Grant Manager. Added the possibility to extract grants as SQL script.
  4. Function Editor.
  • In case a function is modified, when calling the debugger, the program asks to compile this function, debug it without compiling and debug the older version of the function.
  • In some cases the syntax checking worked incorrectly. Fixed now.
  • After being compiled the cursor changed its position in the function body. Fixed now.
  5. Query Data.
  • Now the cursor data can be opened for the refcursor results (if running within a transaction).
  • 'Union' was highlighted as alias, if it was placed next to the FROM section. Fixed now.
  • When executing a query with nested comments, an error occurred. Fixed now.
  6. Restore Database wizard. Now it correctly works with very large SQL files.
  7. DB Explorer.
  • When opening the enum type a new form opened, even if the other editor of this type was already opened. Fixed now.
  • If the "Sort by Aliases" mode is on and "Show arguments as child nodes" is set for displaying the function, the function arguments were sorted in alphabetical order that led into error. Fixed now.
  8. Extract Database wizard.
  • When using PostgreSQL 9.1 and higher a query was executed to the pg_authid system table, and if having no permissions it caused an error. Fixed now.
  • When extracting composite types for array fields the number of array dimensions was not taken into account. Fixed now.
  9. Editor Options. The background color settings were applied to object description fields, but foreground color settings were not. Fixed now.
  10. Database Designer. If there were no printers set in the system, opening the form caused the "There is no default printer currently selected" error. Fixed now.
  11. View Editor. After a trigger was modified, the information on the Triggers tab was not updated. Fixed now.
  12. Search in Metadata. Searches are not performed in temporary objects now.
  13. In the Floating windows environment mode the Windows Taskbar appeared upon launching the program, even it was hidden in the previous session. Fixed now.
  14. Create Report wizard. The selected report style could not be applied to the report. Fixed now.
  15. Dependency Tree. The dependence between parent and inherited tables could not be shown in the subobject display mode.
  16. New Table form. When pressing Ctrl + Insert the Add filed dialog popped up, even if there was another active tab. Fixed now.
  17. Many other improvements and bugfixes.

Version 5.2.0.1

  1. Added support of new PostgreSQL 9.2 features:
  • Support of range types
  • Support of SMALLSERIAL data type
  • Support of privileges on data types
  • Support of not validated и non-inheritable check constraints
  • Support for renaming constraints
  • Support of the SP-GiST index access method
  • Support of the security_barrier option for views
  2. Database Designer.
  • Now views and functions can be added to a diagram
  • Added the possibility to display attribute properties (optionality, keys, etc.) in parentheses after the attribute name and type.
  • Diagram print options are now saved in the diagram file.
  • Added the possibility to display diagram print margins.
  • Added the possibility to drag and drop schemes on the diagram.
  • When loading a diagram from the file the connection line position was not restored. Fixed now.
  • After loading a diagram and switching between diagram pages a value in the zoom field was not updated. Fixed now.
  3. Function Editor.
  • Added the possibility to check SQL syntax in the function body. Also the "Check syntax after compilation" option is added.
  • Added support of function configuration parameters.
  • When formatting a function body using Quick Code | Format, extra spaces appeared in the declarations of %rowtype and %type variables that caused a compilation error. Fixed now.
  4. Backup Database wizard.
  • Added the possibility to connect to a server through an SSH-tunnel.
  • Sometimes in databases with large tables an error saying that pg_dump process did not answer occurred, though the execution itself continued as normal. Fixed now.
  5. Restore Database wizard.
  • Added the possibility to connect to a server through an SSH-tunnel.
  • Added a progress bar when restoring data from an SQL file.
  • When restoring COPY commands with large datasets from SQL files, the "Out of memory» error occurred. Fixed now.
  6. Export/Import Data.
  • Now in most cases the exported data is not re-requested.
  • Some errors occurring during export/import operations are fixed now.
  7. Query Datas.
  • Code Completion now allows you to select variable fields of composite and % rowtype types in the PL/pgSQL function body.
  • "Save file as" dialog. The last selected value of the "Don’t add 'Byte-order-mark' to Unicode files" option is now saved between sessions just as Charset.
  8. Function Debugger.
  • Added support of the RAISE EXCEPTION 'message' USING ERRCODE = 'XXXXX' statement.
  • Added support of USING expression in the OPEN CURSOR command.
  • Added support of Unicode strings.
  9. Change Management. Added support of VisualSVN Server.
  10. Query Data. Now the query execution time is displayed more accurately with no additional cost for the program.
  11. Foreign Key Editor. Added support of foreign keys without validation (PostgreSQL 9.1 and higher).
  12. Server status. Added the "Application name" column to the Connections list.
  13. Data Frame.
  • When inserting data from a clipboard, geometry field data with uppercase characters in the field name could not be inserted. Fixed now.
  • When executing the "Set the value of | Set to the empty string" command, an extra space instead of an empty string was inserted for large varchar fields. Fixed now.
  • Filtering ​​GUID values caused an error. Fixed now.
  • Editing XML fields on PostgreSQL version 9.0 and higher in some cases caused an error. Fixed now.
  • Blob View tab was not available for XML fields, if the data did not contain Blob fields of different types. Fixed now.
  14. Database Explorer.
  • Database Tree. Now there are pseudo- and not defined types displayed in the Base Types branch.
  • Object name hints not fitting to width could not be displayed. Fixed now.
  15. Object Editor. Permissions tab. The "Grant All" option no longer assigns permissions to owner.
  16. Extract Metadata. DROP statements were not written for Enum types. Fixed now.
  17. Extensions. The program hung after installing PostGIS extensions. Fixed now.
  18. SQL Script. When executing the COPY command with large dataset from an SQL file, the "Out of memory" error occurred.
  19. HTML Report. In some cases national characters in object names were displayed incorrectly in the generated report. Fixed now.
  20. SQL Monitor. EventTime was displayed improperly. Fixed now.
  21. Save Settings Wizard. The settings of SQL Formatter, Global Shortcuts and Object Templates could not be saved. Fixed now.
  22. Many other improvements and bugfixes.

Version 5.1.0.1

  1. Added support of new PostgreSQL 9.1 features:
    • Support of collations.
    • Support of extensions (the Database Extensions tool in the Services main menu).
    • Support of view triggers.
    • Support of ALTER composite and ENUM types
    • Support of unlogged tables.
  2. Backup Database wizard. Added the support of creation of backup copies for PostgreSQL 9.1.
  3. Added the support of the column list for UPDATE triggers (PostgreSQL 9.0 and higher).
  4. Function debugger. Added the possibility to debug trigger functions.
  5. Function Editor.
    • Added the Ctrl+H shortcut to hide/display function header controls.
    • Added the possibility to quickly specify the returned void and trigger types.
    • Now in the form header for functions with multiple parameters, the parameter list is truncated to fit the information about the database and server as well.
    • Now in the Tools | Object Editors section of the Environment Options dialogue, it is possible to set the default values for the “Execute with definer's privileges” property for CREATE functions.
    • The Ref Cursor type is transferred to the standard type section in the selection list of the returned values now.
    • The context menu items in the return table fields list were always disabled. Fixed now.
    • When performing any function in the editor, if setting some large absolute values ​​for BIGINT, a value was passed into the function incorrectly. Fixed now.
    • When closing the function editor with a large number of parameters, the “Failed to create key XXX” error occurred. Fixed now.
    • Variables with the “< table field name >%type” were not reflected in the code completion list. Fixed now.
  6. Trigger Editor. Added the Ctrl+H shortcut to hide/display the trigger caption controls.
  7. Change Management. Added the support of Slik Subversion client. Also the support of CollabNet Subversion client for Subversion.
  8. Added the possibility to export table data into the file in many tools.
  9. Check Constraint Editor. Added the possibility to set comments for constraints.
  10. Foreign Key Editor. Now the form size can be changed.
  11. To-Do Item Editor. When opening a form, the focus is set on the input text field now. Added the shortcut keys for switching to all input fields.
  12. Data Grid.
    • If while closing the form with the data grid, the record was only changed, but not posted, the program now asks to save/reset changes in the record.
    • The size of the numeric datatype fields with precision 15 or more was determined incorrectly - it was not allowed to enter large values. Fixed now.
  13. Query Data.
    • If with the disabled “Show the result for each query” option, there was a statement separator (;) next to a comment after the SELECT query text, the result was empty. Fixed now.
    • The Ctrl+N shortcut of adding a new query tab did not work. Fixed now.
    • When using the Azeri (Latin) locale some characters displayed incorrectly. Fixed now.
    • With the enabled “Allow using parameters in the query text” option the rows with a colon in the comments were also considered as query parameters, and while executing the query the input dialogue of values appeared. Fixed now.
  14. Database Designer.
    • After deleting a table from the diagram, saving and restarting the diagram, the deleted table appeared again. Fixed now.
    • In the “Floating windows environment” mode in some cases the diagram field became inactive, it did not respond to mouse clicks and did not allow adding a table. Fixed now.
  15. Design Query.
    • Queries, having a statement in the parsing join condition, gave an error. Fixed now.
    • In the “Floating windows environment” mode after having moved the courser over some tabs, they were drawn incorrectly. Fixed now.
  16. Function debugger.
    • When debugging functions with separate CASE statements, an error occurred. Fixed now.
    • If outer and inner code blocks had variables with the same name, the displayed value of the variable was not changed during being transferred into the inner block. Fixed now.
    • In some cases when debugging functions that use the BIGINT variables, the "Overflow while converting variant of type (int64) into type (integer)" error occurred. Fixed now.
  17. Server Status.
    • Even being disconnected from the server, the timer information continued to be updated, and each time an error occurred. Fixed now.
    • If after being disconnected, the server became available again, the connection was not restored even if pressing the “Refresh” button – the form had to be reopened. Fixed now.
  18. View Editor. The Dependency tab. In some cases not all dependencies were shown. Fixed now.
  19. Extract Database. In server version 8.2 and higher, in some cases the CREATE SEQUENCE statement followed the CREATE TABLE statement. Fixed now.
  20. Export as SQL script. When creating a non-PostgreSQL script, the INSERT statements were generated with errors. Fixed now.
  21. Create Table form. If the “Unique” option is specified for the filed, while saving the table this option did not reach the script and it was not saved. Fixed now.
  22. User manager. If the “Change management” option is switched on for the first database of the host, and there are no any connected databases of this host, when creating a new role and while saving, an AV error occurred. Fixed now.
  23. Restore Database wizard. When restoring an SQL file with the CONNECT statement, an error occurred. Fixed now.
  24. Index Editor. When adding a new Index key from the context menu, the “Could not convert variant type (Null) into type (OleStr)” error occurred. Fixed now.
  25. Grant Manager.
    • Double-clicking on an empty field or on a grid header was interpreted as double-clicking on an active cell. Fixed now.
    • For the role, which name was a substring of another rolename, the cumulative rights of these two roles were shown. Fixed now.
  26. Save Settings wizard. When saving keyboard templates to the file and restoring them on another PC, the templates with line brakes were not restored. Fixed now.
  27. DB Explorer. When registering a database in one program copy, this database also appeared in the tree of another opened copy, however its Change management settings were empty. Fixed now.
  28. Print Metadata. The page size in the template for tables A4 was incorrect. Fixed now.
  29. SQL Script. The type and object names of some SQL statements were determined incorrectly for being displayed in the Statements explorer.
  30. Vacuum Tables and Analyze Tables wizards. Even when selecting separate tables, the action was performed on all tables in the database. Fixed now.
  31. Other small improvements and bugfixes.

Version 5.0.0.1

  1. The Change Management tool is added. It helps to organize the control of the database development process: allows to rollback the database to the certain time, work with different database branches, view the history of changes, etc. It is integrated into the following version control systems: CVS, Subversion, Visual SourceSafe, TFS.
  2. Added the Database Comparer tool which allows getting a script to synchronize the database structure.
  3. The Search in Metadata tool is implemented for performing the quick search within the scope of database metadata. The tool allows you to set various search conditions and view the results.
  4. Database Designer.
    • Added the 'Undo' and 'Redo' operations
    • Now it is possible to select schemas for reverse engineering.
    • Added tools for formatting diagram objects: setting fonts, colors, etc.
  5. HTML Report. Now it is possible to define the report visual style.
  6. Added the Database Registration Manager which allows adding and deleting database registrations quickly.
  7. Added the Instance Manager service which allows checking the service status of PostgreSQL server and staring/stopping the service.
  8. Added the possibility to define shortcuts not only for Query Data commands, but for some other commands too (Environment Options | Global Shortcuts).
  9. Object names in DDL are not quoted now if it is not necessary.
  10. SQL Formatter now allows formatting DDL statements.
  11. The switching between windows is now performed with the Ctrl + Tab shortcut.
  12. Added the possibility to duplicate objects in other databases by drag-and-dropping them in DB Explorer.
  13. Many other small improvements and bugfixes.

Version 4.8.0.1

  1. Added support of new PostgreSQL 8.4 features.
  • Support of exclusion constrains.
  • Support of the ‘when’ clause for triggers.
  • Support of new versions of pg_dump/pg_restore in the Backup Database and Restore Database wizards.
  • Added the ‘Explain buffers usage’ option for the query execution plan.
  • Fixed an error occurred after creating a trigger that had function arguments.
  2. Function Editor. Now when pressing the Tab button in the parameters table, the focus is moved to the next table cell.
  3. Function Editor. When launching a function, it was not possible to enter the time value manually for the timestamp type in the dialog of entering parameters. Fixed now.
  4. DB Explorer. If the display of system objects is enabled, the table's row types are displayed in the Composite Types branch.
  5. Table Editor. The commands of creating/editing/deleting rules did not work on the navigation bar of the DB Explorer. Fixed now.
  6. When an SSH connection was lost, it was possible to restore it only after the program restart. Fixed now.
  7. Function Debugger. It was not possible to set a value with more than 10 digits for the numeric parameter type. Fixed now.
  8. In SQL editors and grid it was not possible to enter some national characters using the keyboard. Fixed now.
  9. Database Statistics. The value of the All objects/User objects/System objects field was ignored after refreshing: all objects were displayed. Fixed now.
  10. Design Query. Queries containing conditions based on the true/false were parsed incorrectly. Fixed now.
  11. Other small improvements and bugfixes.

Version 4.7.0.1

  • Support of column level privileges is added (for PostgreSQL 8.4).
  • Grant Manager and Permissions tab of the Object Editor. The support of the Truncate privilege is added (for PostgreSQL 8.4).
  • SQL editors.

Tick Added the possibility to use code folding for regions – parts that are limited by -- region and --endregion.

Tick The file encoding selected in the Open/Save file dialog is saved and then used when opening/saving files next time.

Tick The Undo command didn’t work for cancellation of the current line commenting (Ctrl+/).

  • Server Status. The Refresh Rate is now saved between working sessions.
  • Table Editor, Data tab.

Tick The ‘Include Data of Descendant Tables’ option is added to the toolbar for tables which have descendants.

Tick If a table contained a field with the name written in the upper case, an error occurred when sorting by that field. Fixed now.

Tick Non-English names of fields were displayed incorrectly. Fixed now.

Tick When connecting through HTTP and on inserting data into a table with the serial field, an error occurred if the search_path for the given user had schemes which were absent in a database (for the mode with disabled transactions). Fixed now.

Tick The ‘Set Empty String’ context menu item was always disabled for VARCHAR fields with unlimited size. Fixed now.

  • Aggregate Editor. Now it is possible to select domain as an input data type when creating aggregates (PostgreSQL 8.2 and higher).
  • Extract Database.

Tick If the path to the script file contains folders which do not exist, they are created automatically.

Tick Sometimes the wrong script was generated when extracting a function with the parameter from a different scheme than the scheme where the function is from.

  • Query Data.

Tick The Ctrl+D shortcut is added for the ‘Show Results on Edit Tab’ command.

Tick With the certain options combination set, all queries resulted in “0 records fetched”. Fixed now.

  • The Input types in the aggregate DDL are now arranged in a column.
  • Key mapping. The confirmation dialog is now displayed on deleting a scheme and key combinations.
  • Create Table form. The default value for the ‘With oids’ option is now ‘off’, as the same default value is set on the server itself starting from version 8.1.
  • When registering the first database and then unregistering a host or a database, an Access Violation error occurred. Fixed now.
  • Database Designer. If the object list was arranged in a tree, the double click on a scheme resulted in an Access Violation error. Fixed now.
  • Object Editors, Dependencies tab. If a non-English localization was set in the program, switching to the tab resulted in the ‘Floating point division by zero’ error.
  • Fixed some errors occurred when working with the row and record types in the Function Debugger.
  • If a storage parameter other than fillfactor was set for a table, an error occurred on connecting to a database. Fixed now.
  • Design Query.

Tick Non-English names of fields were displayed incorrectly. Fixed now.

Tick If a table or a field name was written in the lower case while in the query the same name was written in the upper case and was not quoted, an error occurred. Fixed now.

  • Function Editor. After executing a function which returned a record set, the Ctrl+Ins and Shift+Ins shortcuts stopped working in the function body editor. Fixed now.
  • Other minor improvements and bug-fixes.

Version 4.6.0.1

  • Added support of new PostgreSQL 8.4 features:

Tick Variadic functions; functions returning table; function argument default values

Tick ON TRUNCATE triggers

Tick SELECT queries containing WITH clause

Tick pg_dump/pg_restore options (options were added to the Backup Database and Restore Database wizards)

Tick start value in sequence

  • Query Data:

Tick Using macro is now possible in Query Data and SQL Script

Tick Highlighting of the corresponding brackets is added

Tick Fixed several bugs concerning the incorrect parsing of table aliases in queries

Tick The line with an error was not highlighted correctly even if the error message contained the correct information. Fixed now

Tick Query interruption is now performed via libpg.dll instead of the pg_cancel_backend function. It is not necessary to be a superuser to interrupt your own query

Tick If a file name and location were too long for the window title, the program used to cut the filename. Now it cuts the file location

Tick When a query returned the Infinity value to a timestamp filed, the program used to display this value as Null. Fixed now

  • Data View:

Tick When viewing table data, BLOB data are now loaded from server only after it is addressed to

Tick The support of the Infinity, -Infinity and NaN values is added for ‘real’ and ‘double precision’ fields

Tick The 'Perform data sorting on client' and 'Perform data filtration on client' options were removed. The program now selects the optimal mode automatically

Tick A syntax error sometimes occurred on inserting huge data to a bytea field. Fixed now

  • Function Debugger:

Tick The RETURN QUERY and RETURNING … INTO … statements are now supported

Tick An error occurred on fetching data from ‘for execute’ cursor. Fixed now

Tick A syntax error used to occur if a function contained FOR … IN EXECUTE … LOOP statement. Fixed now

  • Extract Database:

Tick Non-user objects used to be loaded when extracting a whole database. Fixed now

Tick The Add OID into object comments option is added

Tick The speed of the data extraction increased

Tick The constraints’ description was extracted as COMMENT ON INDEX that resulted in an error. Fixed now

  • Function Editor:

Tick Cursor data returning by a function can now be exported

Tick The ‘List index out of bounds’ error occurred when editing some functions’ body. Fixed now

Tick When compiling a function returning data of the composite type, the utility generated the wrong script. Fixed now

  • Functions’ DDL:

Tick Arguments are ordered in a column now

Tick The Parameter name was not quoted even if it was a key word. Fixed now

Tick The “char” (pg_catalog.char) parameter was displayed as CHAR. Fixed now

  • Changing Metadata:

Tick The 'Recompile with Double Timeout' and 'Recompile with Unlimited Timeout' buttons now appear if the script execution was stopped due to timeout limit exceeding

Tick Monospaced font is used for error messages containing code fragment and error position pointer

  • Grant Manager: when granting privileges to a table with a SERIAL field, the utility suggests granting rights to the corresponding sequence
  • SQL Script: if a file name and location were too long for the window title, the program used to cut the filename. Now it cuts the file location
  • Export as SQL Script: when a table definition was formed during the export to PostgreSQL, field types used to be defined incorrectly. Fixed now
  • DB Explorer: the 'Restart Sequence' command is added to the Task submenu of the context menu
  • Data Export: when exporting data of the decimal type with the precision more than 14 digits, the numbers were rounded to the 4th decimal digit. Fixed now
  • Table Editor: the Refresh command didn’t work at the Description tab. Fixed now
  • The wrong script was generated when NOT NULL fields were added to a table containing default values. Fixed now
  • View Editor: sometimes the query text was formatted improperly. Fixed now
  • Print Metadata: the long function title used to hide the part of the function text in the report. Fixed now
  • Visual DB Designer: if a field that links tables was dropped and diagram containing these tables was opened, the “List index out of bounds” error used to occur. Fixed now
  • SQL Monitor, Backup/Restore wizards: non-English messages weren’t converted from UTF-8 to Unicode. Fixed now
  • Fixed some errors that occurred when working in the 'Floating windows environment' mode

Version 4.5.0.1

  • Database Registration Info dialog:

Tick most of the options from the Grid | Data Options section of the Environment Options dialog can now be specified individually for each of the registered databases in the Database Registration Info dialog. The values specified on the Grid | Data Options page will be applied as default settings for newly registered databases

Tick the 'Schema-organized database tree' option is added. With this option disabled, the object tree is built without grouping by schemas

Tick metadata and Query Data logs can now be saved in UNICODE or ANSI

  • Design Query:

Tick when a table is added into a query, its foreign key connections to other tables participating in this query are reflected by JOIN statements

Tick in some cases renaming a table and moving to the SQL tab resulted in the “Cannot bind JOIN expression” error. Fixed now

  • Function Editor:

Tick the results of functions returning cursor can now be viewed

Tick if the DOUBLE PRECISION argument value was set to “0”, the function execution led to the substitution of this value with “NULL”. Fixed now

  • The Unicode support is implemented in function bodies, views, rules, check constraints, object description, field default values, domains and in a number of object properties
  • DB Explorer:

Tick many PostgreSQL add-in objects are considered to be system objects and aren’t displayed in the DB Explorer tree if the Show system objects option is disabled for the database

Tick the Find Object dialog has been improved

Tick the button for switching search mode is added to the Search Panel toolbar

Tick the possibility to reorder hosts using drag-and-drop is implemented

Tick the program saves the information about the last opened database before shutdown. When the application is started next time, this database will be automatically selected in the DB Explorer tree

Tick double-clicking an object group node folds and unfolds it

  • Database Designer:

Tick tables are arranged more compactly in the reverse engineering mode

Tick alignment options did not work when a diagram was opened from the file

Tick Some printers could not print field and table icons. Fixed now

  • Data View | Blob View: added the XML tab allowing you to view XML data as a tree
  • Data Grid: The method of work in the asynchronous mode is changed – the usage of a separate connection for each Data Grid makes it possible to perform simultaneous fetching without losing the ability to use other functions of the program
  • Extract Database, Export as SQL Script: Now the script is directly generated in the selected charset which reduces the script generation time
  • Options: The ability to apply default settings (to all or just a separate category of options) is implemented for all option dialogs
  • View Editor, Rule Editor: when editing a view or rule, the SQL query is formatted with SQL Formatter. DDL of views no more contains extra brackets in expressions
  • Now a role can be set as an object owner (available for PostgreSQL version 8.1 and higher)
  • Windows List: Close All Database Windows command is implemented
  • Foreign Key Editor: Now there is a possibility to view or edit foreign key description
  • The Serial fields as integer option value is now taken into account not only in table DDL, but also in all cases when the field type is displayed
  • New option was added to the Object Editors tab of the Environment Options dialog. It allows you to define whether to split function options into several lines in DDL or to display all options in one line
  • Table Editor: Export Data, Import Data and Export as SQL Script wizards can be now accessed from the editor toolbar even if the data tab is not active
  • Save Settings wizard: Now when saving settings to the existing file, the program suggests that you overwrite the file or make the new file unique by adding the current date and time to the file name
  • Check Constraint Editor: Now the size of the editor window can be changed; it is also saved for future sessions
  • Data Grid: The mouse cursor color changes if the grid is not active
  • Query Data: Creation of queries with identical names was allowed. Fixed now
  • Code Parameters:

Tick code parameters were not sometimes displayed for the second and further function arguments. Fixed now

Tick if several functions were created with the same names but different arguments, code parameters were shown only for one of these functions. Fixed now

Tick if the automatic display of code parameters was disabled, it was impossible to access parameters even with the Ctrl+Shift+Space shortcut. Fixed now

  • user-defined array types used to be displayed improperly in DDL. Fixed now
  • Query Data:

Tick several errors concerning SQL code highlighting were fixed

Tick when saving data to a file using any charset different from Unicode, further opening of the save dialog would set the charset to Unicode

  • If an error occurred on saving an object while using HTTP tunneling, it was not displayed at the Changing Metadata window. This made it possible to commit changes, though no changes were really made
  • Relations of composite and table types with other objects were not displayed in the Dependency Tree and at the Dependencies tab. Fixed now
  • When editing or deleting a record containing polygon and/or point field, an error sometimes occurred. Fixed now
  • Function Debugger: a syntax error occurred on opening function with a FOR … IN construction. Fixed now
  • Numeric fields of high precision used to be edited and displayed incorrectly in the data grid. Fixed now
  • SERIAL fields’ sequences values were not restored after reordering of columns. Fixed now
  • Editing money fields resulted in an error if PostgreSQL server parameters were set in a specific way. Fixed now
  • Database Properties: an error occurred on saving a database whose description contained the back slash ('\') character. Fixed now
  • Other minor improvements and bug-fixes

Version 4.4.0.1

  • Implemented Backup Database and Restore Database Wizards allowing one to perform backup/restore operations with the help of pg_dump and pg_restore utilities of PostgreSQL server
  • Aggregate Editor: added support of aggregate functions with multiple arguments; added support of sort operator for MIN- or MAX-like aggregates
  • Function Editor: added support of planner options for PostgreSQL server version 8.3
  • Function Editor: added the Ctrl+Up/Ctrl+Down shortcuts for changing the argument order
  • Function Editor: after recreation of a function, grants on the function were not restored. Fixed now
  • Data grid: support of the PostGIS geometry type; it is possible to view and edit geometry columns in Table Editor; in Query Data columns based on asEWKT, asText function calls are editable
  • Data grid: the 'Use key and changed fields' option is added for searching for records on update/delete (available in the Grid | Data Options section of the Environment Options dialog)
  • Data grid: numeric values of high precision are correctly displayed and edited now
  • Function Debugger: added the 'Run to cursor' command
  • Function Debugger: in case of a syntax error the number of the line containing the error is returned
  • Function Debugger: fixed several errors concerning function execution and added support of some new PL/pgSQL constructions
  • SQL Script: added support for the \connect <database_name> command for setting the current database during script execution
  • SQL Script: the 'Default directory for scripts' option (available in the Setting default directories section of the Database Registration Info dialog) did not work. Fixed now
  • SQL Script: added support of the CREATE RULE statement with the ALSO clause; the end of the statement used to be determined incorrectly
  • After importing data into a table with Import Data Wizard used, and after insertion of records in the data editing mode, the current sequence value is updated for SERIAL and BIGSERIAL fields
  • Tablespace Editor: tablespace size is displayed now
  • HTML Report: added a possibility to change the font size for the DDL section (the corresponding option is added to the Setting additional report options step of the wizard)
  • Index Editor: added the 'Mark as index to cluster table on' option
  • A toolbar with tools from the 'Services' menu is added to the main form
  • Added support of LATIN9 encoding for opening/saving SQL scripts
  • Changing Metadata window: the size and position of the window are saved now
  • It is now possible to insert a tab symbol in the 'Description' area (within the Description tab) of object editors
  • Visual DB Designer: the NOT NULL flag was not displayed for fields based on NOT NULL domains. Fixed now
  • Extract Database: in some cases function definitions were doubled in the extracted script. Fixed now
  • Extract Database: tables created with option WITH OIDS enabled were extracted without this option. Fixed now
  • The position and content of the main form toolbars were not saved. Fixed now
  • The Code Parameters list did not popup for quoted object names. Fixed now
  • Query Data: SQL sorting for grouping queries with ORDER BY clause did not work. Fixed now
  • Other minor improvements and bug-fixes

Version 4.3.0.1

  • Support of new PostgreSQL 8.3 features: support of ENUM data types; support of TSVECTOR, TSQUERY, XML and UUID types; support of arrays of composite types; support of index key sorting order (ASC, DESC; NULLS FIRST, NULLS LAST); support of new PostgreSQL 8.3 statistic data (Database Statistics tool)
  • Support of operator classes in index keys
  • DB Explorer: composite types are now displayed as a separate node within the database objects tree
  • Query Data: Unicode was not supported upon inputting parameters for queries containing parameters' declaration. Fixed now
  • Query Data: when working with several instances of Query Data, Favorite queries were not always saved correctly. Fixed now
  • SQL editors: a number of functions now work faster
  • SQL editors: for some statements code folding worked incorrectly; also, in function DDL code folding is now used to collapse the entire function body
  • SQL editors: the code completion list for table aliases was not opened if used at the end of the query. Fixed now
  • SQL editors: the first word of the statement is displayed in collapsed code parts
  • SQL editors: keyboard templates do not trigger in comments any more
  • SQL editors: the default schemas from the search_path configuration parameter are considered upon filling the code completion list and object links highlight
  • Import Data Wizard: the 'Client encoding' database parameter was ignored, therefore the 'Invalid byte sequence for encoding...' error occurred in some cases. Fixed now
  • Import Data Wizard: the 'Commit changes manually' option did not work. Fixed now
  • Data grid: sub-levels based on a SQL query can now be edited in the Load All Rows mode as well, if the query is built by one table and contains key fields
  • Data grid: upon insertion of text into a grid cell, Shift-Ins resulted in the duplicating field dialog. Fixed now
  • Data grid: depending on the program settings, if a column name contained the dot (.) character, it was impossible to edit the table data. Fixed now
  • When deleting an index, the index name did not contain the schema name in the generated SQL statement. Fixed now
  • Export Data Wizard: when exporting results of queries of certain type, the 'Parser: parse error at end of input' error used to occur. Fixed now
  • SQL Manager wizards: the databases configured for connection via SSH and HTTP were not displayed in database drop-down lists. Fixed now
  • When working with PostgreSQL 8.3, all triggers were displayed as disabled. Fixed now
  • Visual Options: the 'Menus show recently used commands first' option selection was not saved upon closing the application. Fixed now
  • Function Editor: added the Ctrl+Ins and Ctrl+Del shortcuts for adding and removing parameters respectively
  • Create Database Wizard: at the Setting advanced database properties step only parameters that are applicable for the current server version are displayed now
  • Keyboard Templates: when using the Paste command in a template body, applying the template resulted in insertion of the first word only, instead of the entire text from the clipboard. Fixed now
  • Dependency Tree: if the tree building was interrupted, rebuilding was not initiated upon subsequent selection of an object. Fixed now
  • Other minor improvements and bug-fixes

Scroll to top

Version 4.2.0.1

  • Query Data: the editor now works considerably faster; such features as syntax highlight, object hyperlinks are not disabled while processing large scripts
  • Query Data: added the possibility to refresh DB Explorer automatically after successful execution of DDL statements; the option is available in the Tools | Query Data section of the Environment Options dialog
  • Query Data: Fit Column Width command is now automatically enabled for query results
  • Query Data: when exporting results of queries with parameters, the values of the parameters were not considered, and the result datasets were empty. Fixed now
  • Query Data: an error occurred upon exporting results of queries containing cast operators (::). Fixed now
  • Query Data: with keyboard layouts of some East-European languages used, certain symbols were not inputted. Fixed now
  • Query Data: INSERT, UPDATE, DELETE statements with the RETURNING clause (on PostgreSQL 8.2) did not return any result. Fixed now
  • Query Data: in some cases the object schemas were not considered in object hyperlinks. Fixed now
  • DB Explorer: added the Search Panel for quick search within the tree
  • DB Explorer: Window list is now available in the DB Explorer area, the corresponding tab has been added
  • DB Explorer: aliases for the databases that are accessed via SSH and HTTP tunneling are placed into separate server nodes with the corresponding icons
  • DB Explorer: when working in the 'Group functions by names' mode, on creating and deleting a function the changes were displayed incorrectly in the tree. Fixed now
  • Added support for Enterprise DB 8.2
  • Added the Find Option tool which allows one to find the required option in the scope of all program settings, by a word or an expression from the option title
  • Database Designer: NOT NULL fields are now highlighted bold
  • Database Designer: SERIAL and BIGSERIAL fields are now underlined
  • View Editor: added a command for editing a query in Design Query
  • Function Editor: when working with PostgreSQL 8.2, upon adding the OUT parameter an incorrect changing metadata script was generated. Fixed now
  • Function Editor: when working with PostgreSQL 8.2, an error occurred upon execution of a function that returns RECORD. Fixed now
  • Function Editor: an error occurred upon compilation of a function containing OIDVECTOR[] as the OUT parameter. Fixed now
  • Function Editor: the Input parameters window is now resizable
  • Data grid: if a CIRCLE field contained a record with certain values, Error while posting updates occurred on attempt to save changes in data. Fixed now
  • Data grid: if the standard_conforming_strings option was set on the server, an error occurred on editing data that required string escaping. Fixed now
  • Table Editor, Fields tab: the base type is displayed in brackets for fields of domain type
  • Fixed an error that occurred on connection to PostgreSQL 8.3 beta
  • Download File wizard: an error occurred when working with PostgreSQL 8.2
  • Design Query: fixed several errors concerned with inability to parse the query code
  • Cascade/tile windows now works only for non-minimized windows
  • Grant Manager: filter by object name worked only in case of complete match. Fixed now
  • SQL Manager Direct: the date of the latest update was not saved, therefore the form appeared each time when running the application
  • Other minor improvements and bug-fixes

Scroll to top

Version 4.1.0.1

  • Import Data Wizard: import using the COPY command is implemented. To activate this mode, set 'Batch insert' as import type at the Set import and data write type step
  • Now the codepage can be set for a file when opening/saving it in SQL editors
  • The spell checking feature is implemented in SQL editors to check and perform corrections to SQL code automatically. The spell checking parameters can be set on the Spell Checking page of the Editor Options dialog
  • In many object lists the ability to perform incremental search appeared
  • Blob Editor could not be used for text fields. Fixed now
  • Russian localization is added
  • Data Form View: for strings longer than 80 characters the editor for TEXT fields is opened. The 'Word wrap in string fields' option is added as well
  • Data Grid: when inserting data into TEXT fields the data used to get truncated to 8 kb size. Fixed now
  • Code completion: object names in uppercase are inserted in quotes now
  • Code completion: the Code completion window did not open for the first word of the first line in the editor area. Fixed now
  • Query Data: for the table with the name in lowercase in SELECT queries whenever the table name contained capital letters the results of the query turned to be read-only. Fixed now
  • Query Data: when saving the tab content into a file, after moving tabs, the file turned out to be linked to a wrong tab. Fixed now
  • Query Data: in some rare cases one was unable to interrupt query execution; also, with some specific options set, interrupting query execution raised an error and lead to disconnecting from the server. Fixed now
  • Query Data: when several instances of Query Data are used and the content of one of them is being saved, the changes in the content of the other ones are also considered
  • In table DDL the method of checking whether the field is of SERIAL type is improved. Now the field is considered to be of SERIAL type only when its sequence name corresponds to the table name and field name
  • Export Data as SQL Script: When exporting data to a file the warning window is displayed if the file already exists
  • DB Explorer: the Create Database and Drop Database items are added to the context menu
  • DB Explorer: works faster with the databases containing many objects
  • DB Explorer: the Favorite Queries node (when it was created) used to disappear after refreshing. Fixed now
  • Server Configuration, Role Settings: on attempt to add a parameter the AV error occurred. Fixed now
  • In some rare cases the AV error raised when disconnecting from a database. Fixed now
  • HTML Report: at the Selecting object types step the buttons for selecting/excluding all objects are added
  • Download File wizard: when returning to a previous step, the parameters entered were not saved. Fixed now
  • Names of tables in lowercase were not highlighted as links in Query Data if typed in capital letters. Fixed now
  • Table Editor: when creating a foreign key its sign was not refreshed within the Fields tab. Fixed now
  • If in the Lite version of SQL Manager the limit of registered databases was exceeded, an empty-named database used to be added into the DB Explorer tree after reconnect. Fixed now
  • After aligning windows, e.g. by title vertical, the window size and its position used to be lost if any other object was selected at the Object bar of the editor. Fixed now
  • Other minor improvements and bug-fixes

Scroll to top

Version 4.0.0.1

Basic features:

  • Support of UTF8 data in Query Data, Design Query, Grid View, Data Export/Import Wizards
  • Now you can continue working with SQL Manager while a query is being executed in Query Data or Design Query or while table or view data are being loaded in the editor. A query taking too long to execute can be aborted when using PostgreSQL 8.0 and higher
  • New Database Statistics form added; it allows viewing various statistic information on database objects, helps to find weak points in database performance, indicates if it is necessary to create new indices, etc. The corresponding options must be enabled in server configuration file (postgresql.conf.) for collecting statistics
  • All wizards, including Data Export/Import, DB Extract, Copy DB wizards can now be run in the background mode, so that you could continue working with the program
  • New improved Query Data of the Visual Studio 2005 kind with the Code folding function and UNICODE support
  • Improved Data Import Wizard now allows one to import data up to 10 times faster. New import formats have been added: HTML, XML Document, Open Document Format (OpenOffice), Open XML Format (MS Word 2007, MS Excel 2007)
  • Support of new PostgreSQL 8.2 features is implemented: FILLFACTOR parameter for tables and indices; CONNECT permission for databases; USAGE permission for sequences; support of CREATE INDEX CONCURRENTLY; ALTER TABLE [ NO ] INHERIT support; creating domains based on other domains; support of the IF EXISTS clause in DROP operators of the Extract Database wizard; reassigning ownership of all objects owned by a role
  • Object editors now contain the Permissions tab which allows to grant permissions on the object to users and groups
  • Common SQL commands can now be generated from DB Explorer (Script to Query Data, Script to Clipboard). Now you can easily generate such SQL commands as CREATE, ALTER, DROP, SELECT etc for each database object
  • Now you can save your queries within the Favorite Queries folder in DB Explorer; these queries can be stored either locally in the registry (nobody but you will have access to them) or in a special database table (then all or some of your db users will have access to it)
  • Download File wizard has been added; it allows one to download and upload files from/to PostgreSQL server machine using standard PostgreSQL functions and FTP/SFTP protocols
  • Improved Database Designer: new object type - comments - is added. One can now choose whether only object names or fields should be displayed. Now it is possible to select schemas whose tables should be added to the diagram when performing Reverse Engineering
  • Improved Export Data Wizard now works faster. New export formats have been added: XML Document, Open Document Format (OpenOffice), Open XML Format (MS Word 2007, MS Excel 2007)
  • The Database Properties window has been added, which displays database options and allows to change some of them
  • Improved Table Editor: now it is possible to view and change table properties on a new tab
  • The Tasks menu is added to the DB Explorer context menu. It contains common operations which can be performed on the object selected. Also hosts are now named in accordance with the selected connection type (SSH or HTTP tunneling)
  • Improved the report building system
  • Function Debugger: The variable that changed its value at the last step is displayed bold at the Debug Information window. The SQLSTATE and SQLERRM variables are also displayed now
  • Lots of other improvements and bug-fixes

and more...

Scroll to top

Version 3.8.0.1

  • SQL Script: ability to execute selected statements and statement under cursor added
  • SQL Script: ability to execute the statements like COPY FROM STDIN
  • SQL Script: the notices returned by server when executing statements are now displayed at the message list
  • SQL Script: the scheme set via the ‘SET search_path’ operator is now taken in consideration when forming the object name to be displayed in the Explorer
  • SQL Script: the error list was not cleared when loading a file
  • Grant Manager: the ability to set the grants with grant option added
  • Extract Database: now it is possible to extract data as a set of COPY statements
  • Extract Database: as compared with the previous version of the tool, the extract process now takes less time
  • Extract Database: the ‘Dollar-quoted function body’ option is now applied to the function definitions created by Extract Database wizard.
  • SSH tunneling: support of authentication by key
  • SSH tunneling: the ability to establish connection for several hosts/databases at the same time is added
  • Function Debugger: dollar-quoted strings support implemented
  • Function Debugger: SELECT INTO statements are now supported
  • Function Debugger: Variables list: affected rows and result oid added
  • Function Debugger: fixed a bug with incorrect work of a function containing variables like table_name.column_name%TYPE
  • Function Debugger: when executing the ‘Continue’ operator the syntax error used to occur. Fixed now
  • Function Debugger: the RAISE NOTICE command terminated function execution. Fixed now
  • Data Grid: the filter applied for date type fields worked incorrectly if a date format type other then MDY was used in system settings. Fixed now
  • Data Grid: on attempt to apply any filter with the SQL filter and ‘Select only *’ records limitation used the data were displayed incorrectly. Fixed now
  • Data Grid: mouse-wheel scrolling for the Form View is implemented
  • Dependency Tree: with the Show subobjects option enabled the dependencies were displayed not quite correctly. Fixed now
  • Dependency Tree: objects icons were not printed
  • Server Configuration, Parameter List tab: the 'Parameter Group' column added which allows to display the parameters in groups
  • Visual Options: the 'Menus show recently used commands first' option added
  • Editor Options: the ability to set the default colors added
  • Environment Options, DB Explorer section: the 'Refresh object on showing in SQL Assistant' option is added
  • DB Explorer: a newly created object was not listed in the 'Recent Objects' drop-down menu
  • Import Data Wizard: when importing from DBF format, the default values for the boolean type were False and True (instead of required F and T), so it was necessary to change them for the proper ones while processing the data. Fixed now
  • Environment Options, Windows section: the ‘Number of open editors is restricted’ option didn’t work. Fixed now
  • Environment Options, Preferences section: the 'Save desktop on disconnect' option did not apply to rules, indices, triggers and reports
  • Log Viewer: on attempt to open a local PostgreSQL server log the IO error 32 error raised and the current log did not open. Fixed now
  • Other small improvements and bug-fixes

Scroll to top

Version 3.7.0.1

  • Database Registration: the option that allows one to skip refreshing objects on connection to database is added. It is highly recommended to uncheck this option if your database contains many objects or if connection to the database is slow
  • French localization added
  • When editing a view, a script of the DROP VIEW... CREATE VIEW type used to be generated which caused an error if there were objects dependent on that view. Fixed now
  • Editor Options | Quick code: the option specifying whether the table field names should be sorted in Code Completion window is added
  • Function Debugger: Now works properly with the functions containing variables like table.column%TYPE
  • Data Grid: "Word wrap in memo editor" option added (Environment Options | Grid | Advanced)
  • Data Grid: formats set in Grid | Color & Formats were not applied to detail levels. Fixed now
  • Table Editor, Data tab: it was impossible to edit or delete table records containing fields of TSearch2 type. Fixed now
  • SQL Script: SQL Script window now remains open after disconnecting from the database
  • When opening the data of a table with the primary key containing expressions, an error used to occur and the data were not displayed. Fixed now
  • Index and View Editors: when creating a view or an index their description was not saved. Fixed now
  • DB Explorer: after adding an object into the project it did not appear at the project tab. Fixed now
  • DB Explorer: after refreshing the tree the functions whose owner was removed were not displayed. Fixed now
  • DB Explorer: it was impossible to open a report or an index via the Recent Objects menu. Fixed now
  • The 'Expand after connection' options were only applied to languages and tablespaces. Fixed now
  • Field Editor: When changing object type from SERIAL to BIGSERIAL a wrong script used to be generated without taking the existing sequence into account. Fixed now
  • The 'Reset all toolbars and menus' option used to work incorrectly in some rare cases. Fixed now
  • Some options in the Replace Text dialog of the Query Data window used to work incorrectly. Fixed now
  • Several bugs have been fixed that caused incorrect work of the program running on a system with dual display mode enabled
  • Dependency Tree: the 'Save as image' button is now available on the navigation bar
  • Now it is possible to resize the To-Do Item Editor window
  • Enabling/disabling the 'Dollar-quoted function body' option could be applied only after program restart. Fixed now
  • A large number of other small improvements and bug-fixes

Scroll to top

Version 3.6.0.1

  • EnterpriseDB server support implemented
  • Export as SQL Script: now you can specify DBMS server for which the script should be generated
  • Query Data: now it is possible to rename and move query tabs
  • Query Data: query execution time is now displayed in hh:mm:ss format
  • Query Data: in some rare cases during the query execution the Range Check Error message appeared. Fixed now
  • Query Data: for the queries which allow data insert the ability to import data into the table implemented
  • DB Explorer: the 'Add to Projects' command is added. Now objects can be added by specifying them in the corresponding dialog, and not only by dragging into the Projects folder
  • DB Explorer: after table duplication the indices and triggers of the new table were not displayed in the tree. Fixed now
  • Data Grid: the 'Expand All' and 'Collapse All' context menu items added
  • Data Grid: the 'Save column sorting' option is added for the 'Save and restore layout' mode
  • Data Grid: the 'Paste Cell' menu item didn't work in Lite version. Fixed now
  • Data Grid: the SQL sorting mode used to work incorrectly with the field names represented by SQL keywords. Fixed now
  • Data Grid: when scrolling the mouse wheel in the Print Data view DB explorer used to be scrolled also. Fixed now
  • CPU usage significantly decreased
  • Extract Database: fixed the bug with incorrect handling of the functions bearing OUT as a parameter
  • Extract Database: the wizard used to work improperly with the tables named "char". Fixed now
  • SQL editors: opening object editor with the Ctrl+Enter shortcut used to ignore its schema. Fixed now
  • SQL editors: the Ctrl+Shift+Enter shortcut for pointing out the corresponding item in DB Explorer tree worked incorrectly. Fixed now
  • SQL editors: SQL Formatter used to work improperly with ESC sequences in strings. Fixed now
  • SQL editors: the 'Select All' command did not work correctly on text that had very long lines (more than 4096 symbols). Fixed now
  • HTTPS protocol could not be used for HTTP tunneling. Fixed now
  • Object file is displayed now in the DDL for the functions written in C
  • Controls now remain in the toolbars after installing a newer version of the product. To bring them to their default state, you can use the corresponding command from Windows menu or the corresponding button in the Environment Options dialog
  • Environment Options: applying the 'Table details in SQL Assistant' option did not have an effect on DB Explorer. Fixed now
  • Import Data Wizard: when setting fields correspondence for import from Excel, selecting new column causes cursor to move to the first column in grid. Fixed now
  • Database Registration Info: when applying changes, the originality of database aliases used not to be checked. Fixed now
  • Database Designer: switching to another visual scheme did not take any effect on the context menu style. Fixed now
  • Many other small improvements and bug-fixes

Scroll to top

Version 3.5.0.1

  • Ability to view and edit Server Configuration
  • Query Data: Key Mapping is implemented to set the shortcuts for various commands/operations according to your needs
  • Design Query: query execution plan is now displayed as a graphical diagram
  • Dependency Tree: the diagram can now be printed
  • Function, Domain, Sequence, Aggregate editors, Table Properties: now it is possible to change scheme for an object when using PostgreSQL server 8.1
  • Function Editor: ability to edit function parameters if there are no objects dependent on this function
  • Aggregate Editor: now you are able to edit aggregates
  • Aggregate Editor: parameter type of an aggregate that does not examine its input values used to be shown incorrectly. Fixed now
  • It was impossible to change an object name in the Edit User form. Fixed now
  • Query Data: Next Bookmark, Previous Bookmark context menu items added
  • Query Data: with the 'Trim trailing spaces' option on, an attempt to use Code Completion used to clear all the line. Fixed now
  • Query Data: SQL Formatter now correctly works with TYPE CAST operation
  • Query Data: dragging the field names from SQL Assistant works perfectly now
  • Query Data: ability to execute a statement under cursor added
  • Database Designer: there were no changes seen in opened graphical diagram when the table name or any table field was edited. Fixed now
  • Database Designer: it was impossible to drop table via corresponding context menu item when just a field, not the table itself, was selected. Fixed now
  • Database Designer: upon deleting field and following transaction rollback an empty error message used to appear. Fixed now
  • Import Data Wizard: now with the 'Commit changes manually' option switched on at the end of import you will be prompted for an action with transaction
  • Import Data Wizard: ability to resize wizard's window added
  • Import Data Wizard: the 'Division by zero' error used to appear after importing data with the 'Commit changes manually' option switched on. Fixed now
  • Import Data Wizard: upon setting format for fields to import, the 'Generator Value' and 'Constant Value' options used to be ignored. Fixed now
  • Import Data Wizard: having specified user-defined fields to import, the rest of them were filled with empty strings; so that default values defined for the fields were not applied. Fixed now
  • Data Grid: In the Lite version of the product the Grid Mode could not be changed. Fixed now
  • Extract Database: server version is included into comments for the script now
  • Extract Database: in CREATE TABLE statement the quotes before and after table name were missing. Fixed now
  • Extract Database: upon extracting selected functions with 'Character and character varying as char and varchar' option enabled, functions with char and varchar parameters used to be skipped. Fixed now
  • HTML Report: ability to change header/footer of the report added
  • SQL Script: abort executing script confirmation added
  • DB Explorer: it was impossible to open an index or a trigger via the Recent Objects menu. Fixed now
  • DB Explorer: the context menu used to stay on top when switching between applications. Fixed now
  • DB Explorer: after renaming a scheme, it was impossible to access its objects without refreshing the DB Tree. Fixed now
  • DB Explorer: on attempt to delete the object and selecting 'Rollback' in Changing Metadata window it used to disappear from DB tree. Fixed now.
  • Operator Editor: upon creating an operator containing an array-typed parameter, wrong use of quote symbols used to occur for its parameter type. Fixed now
  • Table Editor: in some cases check constraints were not displayed in the Table Explorer tree. Fixed now
  • When creating new sequences and following the 'Compile' action without changing any parameters, the sequence name used to remain empty in the generated script. Fixed now
  • Table Editor, View Editor: on exporting subobject lists, strings larger than 32 symbols used to be truncated. Fixed now
  • Many other small improvements and bug-fixes

Scroll to top

Version 3.4.0.1

  • Query Data: Query execution plan is now displayed as a graphical chart
  • Full roles support on server 8.1
  • Server Status service implemented
  • SQL Formatter: formats SELECT, INSERT, UPDATE, DELETE queries (available from Query Data context menu)
  • Italian localization added (Luigi Covato)
  • SQL Script: now the process of script executing is shown and there is an opportunity to stop this process
  • SQL Script: now you can open several windows at once
  • SQL Script: when option 'Enable parsing' was enabled, editing a large script (> 10 M) caused hanging. Fixed now
  • Data Grid: now when pasting records from the clipboard, you can set correspondences between clipboard columns and query columns
  • Form View: Memo fields editor is extended (can be customized in the Grid | Advanced section of the Environment Options dialog)
  • Data Grid, BLOB View: 'Word Wrap' option is added for text
  • Data Grid: 'Set to Empty String' and other similar operations do not result in posting records in the table any more
  • Data Grid: works correctly with OID fields that have no BLOB object for their values
  • Data Grid: 'OID columns as BLOB' option added (except for fields with the name oid)
  • Sequences can now be renamed
  • Grant Manager: Permissions for groups are now displayed on server 8.1
  • Grant Manager: When switching databases the 'Record index is out of bounds' error occurred sometimes. Fixed now
  • Report Designer and Report Editor: support HTTP connection to database
  • Design Query: saves queries between sessions
  • Query Data: now there are no limitations for the size of edited scripts
  • Database Registration Info: the feature Font Charset was not saved. Fixed now
  • When there were any connected databases, the process of switching between program languages took a long time. Fixed now
  • The needed documentation page did not open for some forms when pressing F1. Fixed now
  • If a user who connected to the database did not have rights for all schemas, sometimes errors were emerged. The bugs are now fixed
  • DB Explorer: after deleting the index or trigger, it was not deleted from the tree
  • DB Explorer: did not work correctly for View function. Fixed now
  • In some cases Design Query hung when parsing queries containing cast operator "::". Fixed now
  • When deleting a table opened on the Data tab, the program used to freeze, or the operation was aborted by timeout. Fixed now
  • Query Data border draws in accordance with the current visual scheme
  • Function Debugger: The operation of getting array element according to its index resulted in an error when working with server 7.2
  • Table Editor: double-click on the index in Table Explorer did not open its editor. Fixed now
  • After renaming an object in DB Explorer, the context menu was not updated. Fixed now
  • Other improvements and bug-fixes

Scroll to top

Version 3.3.0.1

  • German (Michael Albrecht), Dutch (Bert Herngreen) and Portuguese Brazil (Wilton Ruffato Wonrath and Rogerio Augusto Bassete) localizations are added
  • Function Editor: IN/OUT parameters support, which appeared in PostgreSQL server 8.1, is added
  • Copy Data to/from File wizards. CSV format support for server 8 and higher is added
  • Group manager and User manager can work with HTTP and SSH now
  • New Editor Options are added: "Trim trailing spaces", "Drag and drop text", "Group undo", "Keep caret horizontal position"
  • Export/Import wizards: Items "Save Current Settings as Default" and "Reset Saved Settings" are added to Templates drop-down menu
  • Code completion: did not work for table fields. Now fixed
  • Code completion: required the exact correspondence of the object name case. Now fixed
  • Code completion: when opened in modal forms, did not close by clicking Esc button. Now fixed
  • Database Designer: the context menu for foreign key did not open - the "No argument for format" error occurred. Fixed now
  • Window list: a context menu is added
  • Field Editor: standard types, when entered in combo box for selecting the field type, are auto-filled now
  • Grid: Moving column to the group field did not work with SQL Filter and SQL Sort options enabled. Fixed now
  • Export Data Wizard: the 'Finish' button which can be pushed at any step is added
  • Domain Editor: It was impossible to remove domain check constraint. Fixed now
  • SQL editors: dragging of the selected text downwards worked incorrectly
  • SQL editors: "undo" function after text dragging resulted in violation of the text integrity
  • SQL editors: when going to the line number by clicking Alt+G, cursor position data in the status line did not change
  • SQL editors: link did not work without the exact correspondence of the object name case
  • Save settings: multi-line keyboard templates were restored empty from the file. Fixed now
  • Keyboard templates: #Date tag gave the wrong date. Fixed now
  • "Don't save query text" option is added in Query Data
  • View Editor: empty bars on the Data tab appeared after closing the form. Fixed now
  • When editing data in an updatable view 'Error while posting updates' message emerged. Fixed now
  • Table Editor: if toolbars were disabled, navigation panes and toolbars under the Data tabs of all opened forms disappeared when closing the Environment Options dialog. Fixed now
  • Enabling Allow parameters in SQL (the Tools section of the Environment Options dialog) was unavailable for open Design Query and Query Data widows. Fixed now
  • Grid: filtering by the value that contains an apostrophe character did not work. Fixed now
  • Function Debugger: for an erroneous function, an error message occurred twice when opening. Fixed now
  • After import the data records were shown in grid in the reverse order. Fixed now
  • Other small improvements and bug-fixes

Scroll to top

Version 3.2.0.1

  • Visual Design Query: support of subqueries and UNION joins
  • Visual Design Query: ability to create INSERT/UPDATE/DELETE statements
  • Grid: the 'SQL Filter' option added. Use the 'SQL Filter' and 'SQL Sort' options when limited number of records is fetched in the grid. They allow filtering and sorting records through all the dataset records, instead of only fetched ones
  • Function Debugger: the value of a variable could not be changed. Fixed now
  • When deleting a subobject from a table or view, there was no statement for confirmation of the operation. Fixed now
  • The 'Sort by Aliases' option is now applied to all lists of registered databases in the program
  • Reading database metadata is implemented without using transactions
  • Extract Metadata: extracting data from big tables was slow and sometimes caused “Out of memory” error. Fixed now
  • Extract Metadata: named argument functions were not shown after extracting selected functions. Fixed now
  • Extract Metadata: while extracting tables WITHOUT OIDS and TABLESPACE keywords were not in the correct order. Fixed now
  • Print Metadata: field types were not shown on table printing. Fixed now
  • Print Metadata: primary keys which consist of several columns are shown now in PK column
  • The 'Serial fields as integer in DDL' option is added
  • Modal Visual Design Query form size is variable now
  • Now you can disable deleting records confirmation
  • HTML Report: a semicolon is added to tag '<&nbsp;>: <&nbsp;>'
  • SQL Script: when executing a script from file, the file was uploaded to memory and then was executed. It did not work with big files. Now the script is executed directly from file
  • Query Data: after deleting query, “save to file” might overwrite saved file
  • Field Editor: the Code completion window of the default value editor was not closed after moving focus to another control. Fixed now
  • Sequence Editor: the Backspace button did not work in the 'Next value' field. Fixed now
  • Grant Manager: after changing an object type filter, the current position was not saved. Fixed now
  • Program minimization did not work if the program was closed in the minimized state
  • Field Editor: after entering a large number in the "Number of array dimensions" field the program failed
  • Other small improvements and bug-fixes

Scroll to top

Version 3.1.5.1

  • Create Table and Create Field forms. Added composite types to the field type list
  • When 'Enable floating toolbars' option was on it was possible to undock the main menu, but it was impossible to get it back. Fixed now
  • Table Editor: 'Duplicate Field' and 'Copy List of Field Names to Clipboard' items of the field list context menu are returned now from version 2
  • Query Data: 'Toggle Bookmarks' and 'Go to Bookmarks' items of the context menu did not work
  • Query Data: after opening a form the focus was not placed on the editor
  • Query Data: when calling 'Go to Line Number', 'Find', 'Save to File' using the corresponding shortcut in an active Log tab, the action was performed in fact in Edit tab editor
  • Table Editor and View Editor: sometimes when switching to or from Data tab the Access Violation error arose. Fixed now
  • Import Data Wizard, import from Access: fixed the bug with loading from template: fields map wasn't loaded
  • Import Data Wizard, import from MS Excel: fixed the bug with moving column cells with Skip Rows equaled to 0 and empty first column cell
  • Added infinity values support in grid which was previously implemented in version 2
  • Extract Metadata: data from tables which had inherited tables were extracted incorrectly that led to duplicating records in the inherited tables. Fixed now
  • SQL Script: with double semicolon (;) character in the script, filling the statement tree stopped at this point. Fixed now
  • DB Explorer: in the context menu 'Remove from Project' and 'Drop ...' items had the same shortcuts. Fixed now
  • Load Data Wizard: the progress indicator showed 50% after finishing a task. Fixed now
  • Other small improvements and bug-fixes

Scroll to top

Version 3.1.0.1

  • Copy Database Wizard implemented
  • Now the program notifies itself of new versions released and updates the needed files when SQL Manager Direct is enabled for automatic update
  • Code completion: for table fields their types are shown now
  • DB Explorer: visible/Invisible tab state is saved now
  • DB Explorer: in MDI mode shortcuts on additional tabs didn't work correctly. The bug is fixed
  • DB Explorer: on opening Create menu an Access Violation error emerged if the current tree node was host. The bug is fixed
  • DB Explorer: visible/invisible SQL Assistant state wasn't saved in MDI mode. The bug is fixed
  • DB Explorer: pressing Enter for a table opened its editor and also first table field editor. The bug is fixed
  • DB Explorer: incremental search didn't work on additional tabs. The bug is fixed
  • The TAB key can now be used to shift focus to the next cell in data grid
  • When connecting through SSH, the 'SSL mode' option was not ignored. Now fixed
  • Grid / Form View: checkboxes for setting NULL field value were not shown. Now fixed
  • Surplus object refreshes were made when connecting to a database, which retarded connect on slow lines. The bug is fixed
  • Code completion: the list did not include SQL keywords. The bug is fixed
  • Query Data: with grid filter set in Load Visible Rows mode 'Syntax error' arose on posterior executing of another query. The bug is fixed
  • SQL Script: if there were empty operators limited by the semicolon ';' sign in the text, script execution stopped at this operator. The bug is fixed
  • Table Editor: if object description was not saved when closing form, save request emerged and regardless of the choice the description was saved. The bug is fixed
  • When closing the program some forms closed without showing save request. The bug is fixed
  • Query Data: if a query returned rows in enabled transactions mode, the transaction was committed when executing any posterior query. The bug is fixed
  • SQL editors: after closing Environment Options with save, the cursor restored insert/override mode in SQL editors according to program settings. Now fixed
  • Extract Metadata: when extracting from a non-connected database the list of schemas was not filled. The bug is fixed
  • Other small improvements and bug-fixes

Scroll to top

Version 3.0.0.1

Basic features:

Latest PostgreSQL versions support

  • Compatible with any PostgreSQL versions up to 8.0
  • Changing column types
  • Tablespaces support
  • Support of argument names in functions
  • Support of dollar-quoted strings

Significantly improved user interface

  • Office 11 and Windows XP visual schemes support
  • New well-described Wizard System
  • New useful Navigation bars in most of the program windows
  • New Windows Toolbar to switch between windows, like Windows Task Bar

Improved Database Explorer

  • Creating tabs for any tree node to access it in one-click
  • Working with multiple selected objects at a time
  • Much more convenient toolbar and context menu

Completely remade Database Designer

  • Obvious new look
  • Two diagram notations (IDEF1x and IE)
  • Improved diagram navigation
  • Several pages in one diagram to divide diagram into different subject areas
  • A lot of visual customization options

New powerful data management tools

  • Plenty of useful tools such as data grouping, summarizing, fast searching and filtering
  • Master-Detail View to work with two linked tables at the same time
  • Table and Card Views to see data the way you like
  • Ability to copy and paste selected records
  • Advanced printing system
  • Fully customizable interface

New connection options

  • Access to PostgreSQL server through HTTP protocol in case of Internet access through HTTP proxy only, or if the server doesn't allow direct connections to PostgreSQL
  • SSL connections support to encrypt client/server communications for increased security. Most suitable in case of Internet connection

Improved report management

  • The new Create Report Wizard allows you to create a simple report in a few clicks
  • Managing reports in the same way as if it were a database object: accessing reports directly through the DB Explorer tree

and more...

Scroll to top

Version 2.8.0.1

  • Function Editor: now you can run functions and get their results right from the editor
  • Query Data: implemented the ability of viewing query plan without a need to run it; new options to receive the plan added: Verbose and Analyze
  • We have added support for partial indices
  • Create table form: improved editing abilities in the Fields grid
  • DB Explorer: now when creating an object, the current schema from DB Explorer is selected as its schema
  • Grid: sometimes minutes from date/time fields were saved incorrectly. The problem is solved
  • Query Data: For queries returning incomplete field set, updating a record could cause incorrect results. Fixed now
  • Sometimes when renaming indices an incorrect script was generated. The bug is fixed
  • Shortcuts for tabs didn't work. Now it is solved
  • Print Data table view: defining column width worked only with 'Get column's width from Grid View' option checked. Fixed now
  • Solved the problem when the state of the main form's window was not restored when running the program
  • Query Data: a number of error messages arose after selecting another database and then changing the window size. Fixed now
  • When running the program, you could not shut down Windows. The bug is fixed
  • Database Registration Info: fixed a bug with 'ISO-xxx' client encoding values that did not work correctly
  • In the DB Explorer context menu the 'Drop Database' item was always disabled. Now solved
  • To-Do List: fixed the bug with a second copy of an item that appeared when editing it
  • Now a column with the dot symbol in its name can be deleted
  • Database Designer: resizing the border of a table and clicking on empty space below fields caused the Access Violation error. The bug is fixed
  • Some other minor improvements and bug-fixes

Scroll to top

Version 2.7.0.1

  • Extract Metadata: added the possibility to make scripts for all objects of a schema
  • Query Data: now it is possible to view the query results on the same tab with the query text
  • When connecting to the server 8.0beta5 an error arose, as in this version of the server it is impossible to define tablespace for schema and, therefore, in the system table 'pg_namespace' there is no 'nsptablespace' field. The appropriate changes are made in PostgreSQL Manager.
  • SQL executor now supports dollar-quoted strings
  • In function definition the function body is now shown as a dollar-quoted string. You can disable this using the 'Dollar-quoted Function Body on Server 8.0 and Higher' option on the Object Editors page of the Environment Options dialog
  • There is new possibility to disable showing the Changing Metadata window using the corresponding option in the Confirmations section of the Environment Options dialog
  • Design Query: an Access Violation error emerged when adding a criterion and closing the form. Fixed now
  • 'Make hidden Table Explorer visible on new table window' option is substituted for 'Hide Table Explorer'. A new button is added to the Table Editor toolbar to show/hide the explorer
  • Expressions of indices for server 8.0 beta 5 are shown correctly now
  • Now, when creating SERIAL and BIGSERIAL on server 8.0, the script like ALTER TABLE ADD SERIAL is generated. On creating SERIAL on server 7.4 and lower the maximum value for created sequence is limited now according to INTEGER type
  • BLOBs with OID more than 2147483647 were shown empty. The problem is solved now
  • The error arose and the views were not shown when the user without rights on some schemas usage tried to connect to server. Fixed now
  • Function Editor: sometimes after compiling a function the list of arguments became empty. Fixed now
  • Export Data Wizard: when the 'Current record only' option was selected, the cursor jumped to the first record and the first record was exported. Now solved
  • Environment Options dialog, Grid section: the new 'Autofill Not Null fields w/o default' option is added
  • Now the Help | 'Send bug report to' main menu item is passed to our Support Ticket System
  • Small improvements and bug-fixes

Scroll to top

Version 1.4.0.1 (Linux)

  • We have improved the compatibility with different Linux versions
  • SSL connections management is supported now
  • We have added the support of array field types in the data editing window
  • We have added the possibility to enter a unix-socket instead of the port number like "/tmp/mysql.sock", i.e. to connect to the local server with disabled TCP/IP
  • We have implemented an installer. The program is distributed as a sh-script now instead of archives
  • Several bugfixes in design: displaced fonts, wrong control sizes, invisible combo box captions, etc.
  • Closing the help file often caused the program hang-up. Fixed now
  • The majority of open/save dialogs didn't show files due to the incorrect filters. The issue is resolved
  • We have significantly improved the usability of .txt files importing page
  • Fixed the bug with SQL-Monitor. Now it works correctly after reopening
  • Several serious errors in print preview window are fixed now
  • The bug in register database window caused the 'out of bounds' message. Fixed now
  • Fixed the bug with data editing in tables with bigint fields
  • The problem with execution of the scripts with '--' comments is fixed now

Scroll to top

Version 2.6.0.1

  • We have added tablespaces support on working with server 8.0
  • DB Explorer: now allows renaming schemas, tables, fields, check constraints, functions, triggers, aggregates, languages. You can disable renaming in place by using the 'Rename objects by editing in place' option
  • Now Grant Manager opens and works faster
  • Function Editor: now argument names that have become available in server 8.0 are supported
  • An ability to rename users and groups for server 7.4 and higher is added
  • Field Editor: now allows setting the level of detail of statistics accumulated for a column by ANALYZE
  • Foreign Key Editor: now you can set or change match type of a foreign key
  • Now Function and Trigger editors allow showing/hiding header part of the windows that enlarges the definition editing area. The Environment Options dialog contains options that allow auto hiding a header on opening the editors
  • When a view was recreated, its rules were not recreated and were lost. Fixed now
  • Dependency Tree: now on opening the select object dialog is shown
  • Grant Manager showed privileges incorrectly on system functions. Fixed now
  • Grant Manager didn't show privileges of users whose names contain a dash
  • Code completion: When on entering alphanumerical characters to press Space or shift the cursor, the demonstration was not canceled
  • Code completion: If one typed several characters and pressed Enter for insertion of the word when Code Insight is open - the word was inserted, but Code Insight emerged again. Fixed now
  • When an error occurred on database creating, the second launch after correction of creation parameters returned an access violation error. Fixed now
  • Now Design Query encloses tables' and views' names with upper case letters in quotation marks
  • Grid: If the cell isn't in edit mode when editing the integer field value - on pressing a numerical key and further saving of corrections the previous grid cell value was restored
  • Database Designer: in some cases, when choosing the not-white window color in the monitor settings, a black square emerged on printing a Database Designer diagram
  • Now the default button of the dropping database confirmation dialog is Cancel
  • Query Data: now when dropping query pages, the confirmation dialog emerges
  • Small improvements and bug-fixes

Scroll to top

Version 2.5.0.1

  • Table Editor: now you can cluster your tables using the new Cluster Table service. This service is accessible through the corresponding button on the Table Editor toolbar
  • Print View: now you can customize columns width using the new dialog that is accessible through the Table Column Widths button on the toolbar
  • Now you can connect to PostgreSQL server v7.5-devel (native Windows version)
  • Export to Excel: added an ability to set values of the defined cells, merge cells, and define the page background
  • Import wizard: added an ability to define the error log file name
  • Now you can update and delete table records by only the unique identifier of the record (i.e. primary key or unique index) instead of the complete record value (all fields). To make this feature available check the Use Key Fields Only switch on the Grid page of the Environment Options dialog
  • Print View: now the program saves page settings. You can disable this feature on the Reports page of the Environment Options dialog
  • Now the program correctly shows results of the FETCH statement
  • Query Data: added the Explain Query item to the Run drop-down menu on the toolbar. Check this item to show/hide the query execution plan when executing the query
  • Export as Insert: now the program exports data from views regarding to the current filter settings
  • Fixed a bug that caused the 'Error while posting updates' error when updating the TIME field set to 00:00:00
  • Fixed a bug in the code completion system that slowed down the processor if the selected localization differed from the default one
  • Function Debugger, Modify Variable dialog: now the program correctly drops the NULL flag when changing values of fields. The "Invalid variant type conversation" error appeared when opening NULL fields is fixed now
  • The 'Field XXX must have a value' error appeared when trying to save data of the BLOB field with the NOT NULL flag checked. Now it is fixed
  • Fixed a bug that caused the 'Invalid field size' error when trying to execute SELECT statements that contain the bytea statements (i.e. function calls that return bytea statements)
  • Design Query: now the program correctly parses LIKE statements
  • Design Query: now the program correctly builds query if the table has two or more links
  • Design Query: now you can drag and drop tables to the work area without any difficulties
  • Data Grid: fixed a bug with the improper disabling of the navigation buttons
  • Fixed a bug with usage of fonts that are defined in the Environment Options dialog
  • Now the program correctly adds the name of the newly created view to the DB Explorer tree
  • Form View: now the program correctly displays NULL values of date and time fields
  • Some small improvements and bug-fixes

Scroll to top

Version 2.4.0.1

  • Query Data: now you can use the Shift+Ctrl+Space key combination to view function parameters after you enter a function name in your code
  • Now the program supports domain checks in PostgreSQL 7.4
  • Duplicate Table: in this version you can copy the table data along with the table structure
  • Table Editor: now you can create an updatable view for the table
  • Design Query: now you can create views that are based on queries
  • Now the program asks for a confirmation to load all table records when exporting data if the grid record limit is on
  • Print Data View: now the program displays the table name on each page of the report
  • The Database Metadata Log now contains only records that are executed completely and not rolled back
  • The Database Query Data Log now contains only statements that are executed successfully. You can disable this feature using the corresponding option on the Query Data page of the Environment Options dialog
  • Function Debugger: several improvements and bug-fixes in the variable list
  • The "'' is not a valid integer value." error that appeared when opening a PostgreSQL 7.4 table with a unique INDEX BY statement is fixed now
  • Database Designer: fixed a bug that caused an error when creating links from the drop-down menu of the table
  • Edit Field: fixed a bug that caused an error when displaying dimensions of an array field
  • The "Control has no parent window" error does not appear anymore when starting the program if DB Explorer was hidden in the previous session
  • SQL Script: now the program correctly saves scripts upon pressing the Ctrl+S shortcut
  • Fixed a bug that caused high processor load when typing text in Query Data if the selected interface language differed from the default one
  • Fixed a bug with a button on the Form View tab that shows BLOB content
  • Extract Metadata: Now the program correctly reports about all errors that appear during the extraction process
  • Some small improvements and bug fixes

Scroll to top

Version 2.3.0.1

  • We have implemented a new form for creating tables. Now it allows you to define all the table fields before table creation
  • Database Registration dialog: now you can keep connection with the server alive by checking the Ping Server Every ... Seconds and setting the period between pings
  • Data Grid: now you can filter data in the 'Load Visible Rows' mode
  • Data Grid: now the program exports only the filtered data
  • Data Grid: now navigator buttons are correctly enabled in 'Load Visible Rows' mode
  • Data Grid: now the program correctly refreshes data if the table or query contains memo fields, BLOB fields, large string fields, or array fields
  • Query Data: the 'ERROR: current transaction is aborted, commands ignored until end of transaction block' error that appeared when executing large queries is fixed now
  • Now you can disable the Table Explorer for the current window only
  • Extract Metadata: now you can extract the CHARACTER and CHARACTER VARYING fields as CHAR and VARCHAR. The option is added to the Extract Options tab of the dialog
  • Now the program supports the 'infinity' value of TIMESTAMP fields
  • Reduced the amount of virtual memory that is required for saving BLOB objects to the database
  • Export Data: now the Export dialog automatically adds the file extension to the file name; fixed a bug with exporting data to CSV
  • Fixed several bugs in the Find/Replace commands of the text editor. Now you can use the Ctrl+R shortcut to call the Replace Text dialog
  • SQL Script: now the word wrapping system works correctly in the Messages window
  • Small improvements and bug fixes

Scroll to top

Version 2.2.0.1

  • Significantly improved the data grids: now the data grids support array fields; also added the new navigation panel that is more convenient to use
  • The Code Insight system now supports aliases in SELECT queries
  • Report improvements: XLS and bitmap export, hypertext and URL links in designer and many more
  • We have added Romanian localization to the installation package
  • We have updated the Export Data dialog and fixed some bugs in the export process
  • Data Grid: reduced the memory usage and added the Copy and Paste items to the drop-down menu
  • Grant Manager: fixed a bug with displaying permissions for PostgreSQL v7.4
  • Register Database dialog: added the 'Login prompt before connection' option for SSH connection. The 'Copy Alias from' button works correctly now
  • Design Query: Now you can show/hide system fields. Use the 'Show System Fields' option on the Design Query tab of the Environment Options dialog
  • Environment Options: We have added the 'Convert line end to Linux style in string constants of executed SQL statements' option to the Tools section
  • SQL Script: fixed a bug with the Rollback on Abort option. The Client Encoding and the SQL Timeout parameters works properly now
  • View Editor: fixed a bug with compiling views which contained fields with names in uppercase
  • Fixed bugs with primary and unique keys when recreating tables
  • Fixed a bug with script generation when editing BIGSERIAL and SERIAL fields
  • The Extract Metadata tool generated one-row views' DDLs. Fixed now
  • We have fixed up the parser that forms SELECT statements in views' DDLs
  • Fixed a bug with generating script when creating TIME or TIMESTAMP array fields
  • Create/Drop Database: fixed bugs with SSH connection
  • Some small improvements and bug-fixes

Scroll to top

Version 1.3.0.1 (Linux)

  • Now PostgreSQL Manager supports the PostgreSQL Server v7.4
  • Other small improvements and bug-fixes

Scroll to top

Version 2.1.0.1

  • We have implemented the Dependency Tree tool. Now you can view all the object dependencies in one diagram. To call this tool use the Tools | Dependency Tree main menu item
  • Plpgsql Function Debugger now supports cursors. Besides, we have fixed several bugs in the debugger
  • Several bug fixes in the Extract Metadata Expert. Now this tool generates correct scripts for all objects
  • Import from MS Access: One table appeared several times in the table list. Fixed now
  • The Duplicate Table function now works correctly for PostgreSQL v7.2
  • Sequence Editor: Fixed bug with saving changes of the Next Value field on PostgreSQL v7.4
  • Create Database: Now you can create databases through the SSH connection
  • Now Query Data correctly returns results of the EXPLAIN operator execution on PostgreSQL v7.3 or higher
  • User Manager and Group Manager: added the System ID column
  • Lost names of foreign keys and checks on table recreate. Now fixed
  • Some small changes in function, sequence, and table DDLs
  • Other small improvements and bug-fixes

Scroll to top

Version 2.0.0.1

Basic features:

Support for PostgreSQL 7.4

  • Now PostgreSQL Manager fully supports PostgreSQL server v7.4

Database Designer

  • The Database Designer is implemented. Now it is possible to design your database intuitively using this tool. A lot of features are implemented including reverse engineering, foreign keys support and diagram printing/saving/loading. Customizing of the Database Designer is available on the Options | Environment Options | Tools | Database Designer page

Plpgsql Function Debugger

  • To fix errors or optimize function code you can debug the function step-by-step before compilation, using the Plpgsql Function Debugger. To activate the debugger open the function in Function Editor, then click the "Debug Function" button on the toolbar

HTML Report Generator

  • Now you can generate detailed reports about your database in HTML format. You can call this tool by selecting the "HTML Report" item from the "Tools" menu

Internal SSH client

  • An internal SSH client has been implemented in PostgreSQL Manager. Now it is possible to connect to a remote PostgreSQL server using local port forwarding through the SSH (Secure SHell) tunnel. All the necessary parameters for SSH connection are available in the SSH section of the Database Registration Info dialog, and on the first step of the Register Host Wizard

A number of improvements

  • Improved Data Export and Data Import Wizards: Now you can add charts based on exported data to Excel documents and import data from Excel sheets and XML files
  • Now the program tries to restore the broken connections with the server
  • We have fixed an error on saving BLOBs
  • Now grids automatically switch to the "Load Visible Rows" mode on opening queries with a large amount of result rows
  • Now the program allows you to create an index when creating a foreign key if the referenced table has no index for the foreign key
  • Now the program automatically adds appropriate operators to the script when creating the primary key if the NOT NULL option is unspecified for the fields
  • Some minor improvements and bug-fixes

and more...

Scroll to top

Version 1.8.0.1

  • The Extract Metadata Expert now builds scripts according to the dependencies between objects
  • Added an ability of incremental search to many of the program lists
  • Names of the new objects are converted to lower case on typing now if the "Convert created object's names to lower case" option is checked. You can find this option on the Preferences page of the Environment Options dialog
  • A bug with the "Error while posting updates" message appearance during updating records in a table containing REAL and TIMESTAMP fields, is fixed now
  • Fixed a bug with 50-char limit for displaying or editing values of VARCHAR fields with undefined length
  • During work with a table which contained CHAR/VARCHAR fields with length greater than 8000 chars, the "Invalid field size" message appeared. Fixed now
  • DB Explorer opened on the Windows tab at the program startup. Fixed now
  • Fixed a bug with deleting a wrong function if the database contains two functions with the same names which differ only in char case
  • Fixed a bug with the incorrect DB Explorer tree refreshing after creating functions in some cases
  • Function duplicating in DB Explorer works correctly now if the grouping option is checked
  • PostgreSQL v7.1: some functions were not determined as system functions. Fixed now
  • Table Editor, Duplicate Field: a table name in the UPDATE statement is quoted now.
  • Fixed a bug with restoration of privileges on views and sequences after their recreation
  • Form View: the Not Null option was dropped only after the record saving. Fixed now
  • Reindex: now index names include namespace
  • Export Wizard / Import Wizard: the initial directories to save/load templates are set correctly now
  • Shortcuts for labels work correctly in all forms now
  • Table's DDL: Names for SERIAL and BIGSERIAL fields are quoted now
  • Function's DDL: the return value type is quoted now
  • Query Data: all options from the Transaction Confirmation group work correctly now
  • Query Data: the "column number 4 is out of range 0..3" message doesn't appear any more during the query execution
  • Now Query Data shows correctly all the available notices
  • Query Data / Design Query: the Help buttons do not exist any more
  • SQL Script: the 'Rollback on Abort' option works correctly now
  • SQL Script: statement ranges were not detected correctly in some cases. Fixed now
  • Now Grant Manager generates correct scripts for setting the function's owner and for defining grants for functions with large amount of parameters
  • User Manager / Group Manager: the grid shows all the columns on startup now instead of only last as in previous versions
  • Now User Manager and Group Manager detect SUPERUSER even if the user name contains characters in upper case
  • User Manager / Group Manager: the "User 'xxx' has no privilege to edit users" used to appear twice. Fixed now
  • Several minor bug-fixes and small improvements

Scroll to top

Version 1.2.0.1 (Linux)

  • Now you can view the dependencies of the database objects at the appropriate editor tabs. The Environment Options dialog contains two new options on the Tools tab: 'Automatically expand dependencies' and 'Don't show empty object categories in dependencies'
  • Transactions in grids: In order to decrease a probability of other programs' hang up on editing table editors in PostgreSQL Manager, we have added a possibility to disable transactions in grids. For this purpose 'Use transaction' option on the Tools tab of the Environment Options dialog is provided. If it is on, the grid works as in previous versions: the transaction is active until the grid is closed or the Commit button is pressed; all edited records are blocked until the transaction commit. If this option is off, then the transaction starts and immediately commits (autocommit) on saving each record, which is blocked only for a little time period
  • We have added the statement timeout support for working with server v7.3. You can customize timeouts on the Tools page of the Environment Options dialog. Timeouts are necessary for preventing program hang-up when executing the SQL statement due to the transaction interlocking
  • Now on error in query Query Data tries to find the position of the error in the SQL statement
  • Export as Insert is being called properly now from the Query Data
  • Query Datas: Now you can disable the Smart Tabs mode (when the tab positions are set according to the space characters in the previous non-empty lines). The appropriate options are added to the Editor Options dialog
  • Fixed bug with incorrect saving comments and formatting during saving query in the Query Data
  • Some small corrections and improvements

Scroll to top

Version 1.7.0.1

  • We have added the statement timeout support for working with server v7.3. You can customize timeouts on the Tools page of the Environment Options dialog. Timeouts are necessary for preventing program hang-up upon execution of a SQL statement due to the transaction interlocking
  • We have implemented the new Trigger Editor
  • We have added a new tool - Report Designer. It is a powerful tool for designing reports visually
  • The connection speed is significantly increased with the 'Show table subobjects' option on
  • Incremental search in DB Explorer
  • Now on error in query Query Data tries to find the position of the error in the SQL statement
  • The Print Metadata tool now prints all the table subobject descriptions
  • The Filter Builder dialog is localized now
  • Now you can use the Ctrl+G key combination for switching between the page control tabs
  • The 'Use transaction' option is now located in the Tools section instead of the Grid section of the Environment Options dialog and has effect on the Query Data and Design Query behavior
  • Script is being generated correctly now on updating a table record
  • The program does not hang up any more on changing metadata if a table is open and the "Use transaction" option is disabled
  • The SHOW statement executes correctly on server 7.3 in Query Data now
  • Now Export as Insert is called properly from Query Data
  • No error occurs any more on closing Function Editor, if the edited function had plenty of arguments
  • The TIMESTAMP fields can be edited without any errors now in the Form View mode
  • If Table Editor was closed with the Data tab being active, then on reopening the table its records were loading twice. Fixed now
  • Fixed a bug with multiple display of the grid column after the table recreation or field renaming with the "Save grid view" option on
  • Column widths after changing it and committing transaction with the "Save grid view" option on do not return to their previous values
  • The "Save grid view" option now takes effect on View Editor as well as on other grids
  • The Final Type box now displays correctly in Aggregate Editor
  • Fixed bug with the triggers with their functions removed
  • No error occurs any more on trying to create an index with a "." sign in its name on server 7.2 or 7.1
  • Fixed error with displaying the PUBLIC group in the group list of the User Editor dialog
  • Some minor improvements and small bug-fixes

Scroll to top

Version 1.1.0.1 (Linux)

  • Environment Options: A possibility of defining Qt style is added
  • DB Explorer: The "Add to project" dialog is improved. You can add, delete or modify folders or subfolders of the project from this dialog
  • Main Form: The Database->New Object and Database->Duplicate Object menu items are added
  • Main Form: A possibility of starting other our utilities (PostgreSQL Export, PostgreSQL Import, PostgreSQL Extract) from main form is added. If you've installed some of EMS PostgreSQL Utils, the program will automatically add proper buttons to the Utils toolbar on Main Form for fast calling these utils from PostgreSQL Manager
  • Trigger Editor: A possibility of creating or editing corresponding function is added
  • Data Frame: The "Set Filter..." context menu item works correctly now
  • Server v7.3: Fixed bug with incorrect script generation for creating functions with an argument like ..
  • Field size for TIMESTAMP, TIMESTAMPTZ, TIME, TIMETZ, and INTERVAL shows correctly now
  • Fixed bug with incorrect script generation on adding a TIMETZ field to the table
  • Field size and precision for NUMERIC show correctly now
  • Some small improvements and corrections

Scroll to top

Version 1.6.0.1

  • Now you can view the dependencies of database objects at the appropriate editor tabs. The Environment Options dialog contains two new options on the Tools page: 'Automatically expand dependencies' and 'Don't show empty object categories in dependencies'
  • Transactions in grids: In order to decrease a probability of other programs' hang up on editing in table editors in PostgreSQL Manager, we have added a possibility to disable transactions in grids. For this purpose 'Use transaction' option on the Grid page of the Environment Options dialog is provided. If it is on, the grid works as in previous versions: the transaction is active until the grid is closed or the Commit button is pressed; all edited records are blocked until the transaction commit. If this option is off, then the transaction starts and immediately commits (autocommit) on saving each record, which is blocked only for a little time period
  • Table DDLs now display SERIAL and BIGSERIAL fields correctly
  • SQL editors (Query Data, SQL Script): Now you can disable the Smart Tabs mode (when the tab positions are set according to the space characters in the previous non-empty lines). The appropriate options are added to the Editor Options dialog
  • Insight List: Now object names containing capital letters are enclosed in quotation marks
  • Server v7.3: Fixed a bug with incorrect script generation for creating functions with an argument like ..
  • Now program works correctly after selecting language at the first startup
  • Server v7.3: Sequences for fields SERIAL, BIGSERIAL are no more dropped if a table is edited through recreation
  • Field size for timestamp, TIMESTAMPTZ, TIME, TIMETZ, and INTERVAL shows correctly now
  • BIT, BIT VARYING, TIMESTAMPTZ, and TIMETZ fields are displayed in the grid correctly now; no errors occur on refresh
  • Fixed a bug with incorrect script generation on adding a TIMETZ field to a table
  • No error occurs on changing a field type from any integer to BIGSERIAL now
  • Fixed an error with selecting value editor type after reordering columns with the 'Save Grid View' option on
  • Incorrect script was generated for some of the DB objects on saving a comment with a ' character. Fixed now
  • No error occurs on dropping a view or rule through DB Explorer any more
  • All experts use right DB name on their startup now
  • Register Host Wizard now displays the error message if an error occurs on connecting to server
  • Printing metadata can be called successfully from index, domain or schema editor now
  • Case Code does not modify object names any more
  • Fixed an error with hiding database objects in DB Explorer after deleting the user that owned these objects

Scroll to top

Version 1.0.0.1 (Linux)

The Linux version of PostgreSQL Manager - a powerful GUI tool for PostgreSQL database administration and development.

PostgreSQL Manager for Linux is the same powerful tool for PostgreSQL management as the Windows version. It provides graphical interface for all basic operations: creating/dropping databases, creating/dropping/altering tables, views, functions and other database objects, managing table data, running SQL queries and scripts, etc. Export/import data to/from most popular formats and other unique features are also available in Linux version.

Scroll to top

Version 1.5.0.1

  • MDI Interface implemented. Microsoft Office Style - all program windows are child windows of the main window now. You can customize the Environment Style using the Environment Options dialog
  • Two new localizations added - Italian and French
  • The support of composite types for PostgreSQL v7.3 is implemented
  • The 'Autoconnect on Startup' option was added to the Database Registration Info dialog
  • Table Editor: the Comment columns are added to the lists of fields, foreign keys, checks, indices, rules, and triggers
  • Table Editor | Fields: foreign keys are now indicated with icons similar to primary keys
  • The "Set Defaults to All Child Windows" item was added to the Windows menu. This item sets all the child windows to their default sizes and positions. This function is also available through the Ctrl+Alt+D shortcut
  • Database list in child windows are now grouped by hosts if the Show Hosts option is enabled
  • The new option 'Show only connected databases in drop-down menu' can be found on the Tools page of the Environment Options dialog
  • Now the cursor position is displayed in the SQL areas of view, function and rule editors
  • The caption of the focused column in the grid is now displayed in bold
  • Autofit column widths in the grid works subject to the column name
  • Now you can select custom color from the color select drop-down list on the Grid page of the Environment Options dialog
  • NUMERIC type without setting precision and scale is supported now
  • Table's Details submenu in the View Mode menu of DB Explorer is now duplicated in the View main menu
  • The following buttons are added on the View editor toolbar: Commit, Rollback, Export Data, Export as INSERT, Import Data, and BLOB Editor
  • Design Query: now you can select the sorting mode of the table list, and also drag tables and views from DB Explorer
  • Environment Options dialog, Confirmations section: options enabling/disabling confirmation of transaction commits and rollbacks added
  • Fixed a bug on v7.3 server with the impossibility of editing tables from not-default schemas
  • Design Query on server v7.3. Table names are being written with their namespaces, all the tables and views are displayed, not only from the default namespaces
  • Now on reordering fields, deleting a field, changing the field name or type, the ALTER TABLE OWNER TO statement is not executed if the current user is the table owner
  • A table is not recreated on changing only a field name
  • On server v7.2 tables with foreign keys are not any more edited by recreation
  • The program does not hang up any more on creating/opening a view if a value in the Right Margin editor box on the Display page of the Editor Options dialog is less than 12
  • Now script for editing index on server v7.3 with options Primary or Unique off is generated correctly
  • Now index on v7.3 server created with the CREATE UNIQUE INDEX statement is deleted correctly
  • The Code Case parameter on the Quick Code page in the Editor Options dialog works properly now
  • Fixed bug with displaying only tables and functions in the Windows | Close submenu
  • Database objects are refreshed completely on changing the database in the editor now
  • The toolbars of the object editors are saved properly now
  • Fixed a bug with localizing several forms of some object editors
  • The trial form is localized now
  • Window list is updated on creating a new database object now
  • Fixed several bugs with deleting table subobjects
  • On adding SERIAL and BIGSERIAL fields the NotNull and Unique options are set now
  • Several minor improvements and small bug-fixes

Scroll to top

Version 1.4.0.1

  • A possibility of dropping a table field for servers lower than 7.3 and a possibility of altering the field type added. These operations are implemented through recreating the table. You can use the appropriate options on the Environment Options | Confirmations page to forbid these features
  • Data Export and Import are significantly improved. Export to MS Access and PDF and Import from Access added. Now you can export data to as much as 14 formats and import data from 5 formats
  • Table Editor and View Editor: now column widths for all the tabs are saved
  • The Field Editor interface improved
  • Now on dropping table subobjects in Table Editor a confirmation dialog appears
  • The 'timestamp without time zone' type is interpreted correctly now
  • Now you can edit BIGINT fields freely
  • Fixed bug with setting the length of the BIT fields and defining the length of the BIT and BIT VARYING fields
  • Boolean fields are displayed correctly in the Form View mode
  • Copy to clipboard / paste from clipboard functions work properly now in the Query Data and Design Query grids
  • Reordering fields referenced by some foreign keys is restricted now
  • On reordering fields permissions for the table are restored correctly now
  • Fixed a bug with the 'table doesn't exist' message on selecting a table in DB Explorer, if on reordering table fields the Rollback button was selected in the Compile Window and the Cancel button in Re-order Columns
  • Dropping a table is forbidden now, if table is opened on the Data tab in Table Editor
  • Integer overflow error does not appear any more on deleting table subobjects
  • Some minor improvements and small bug-fixes

Scroll to top

Version 1.3.0.1

  • New data grid: Now it can work in two modes: "Load All Rows" and "Load Visible Rows". The first mode provides some additional features, such as filtering fields, sorting data be several fields, etc. However this mode works slower on tables with large amount of records. The second mode works just as in previous versions. According to this a new option "Load all rows mode as default" appeared on the Grid page of the Environment Options dialog, and in the popup menu a submenu appeared, which allows you to select a mode: "Load All Rows", "Load Visible Rows", or "Default". If you select the "Default" item, the mode is selected according to the option "Load all rows mode as default". The selected mode is stored individually for each table. You can also use another new option "Row multi-selection" on the Grid page of the Environment Options dialog. If this option is enabled, you can select multiple rows in a grid, but in this case navigation in tables with large amount of records is slower
  • Unicode database support - now you can define the client encoding and font char set in the Register Database and Register Host dialogs
  • Functions, returning SET OF are supported now. The appropriate options added to Function Editor
  • Changes in the table Form View: field type is displayed in the field name hint; the Null option is not visible if a field cannot be Null; string and memo fields expanded to the window width
  • Parameters in Analyze and Vacuum services are described more precisely
  • The 'Inherits From' list in the Create Table dialog redesigned
  • In the Environment Options dialog a new page has been added - Tools | Reports, where you can set the sheet size for the reports
  • A possibility to set column widths for Print Data table view added. Use option "Get column's width from Grid View" on the Reports tab of the Environment Options dialog
  • The Find and Replace text functions added to Localization Editor (called by Shift+Ctrl+L)
  • All objects are recreated correctly now while reordering fields
  • Fixed bug 'List index is out of bounds', which rarely appeared on reading the foreign key on server 7.2
  • The update script is generated correctly now on setting the Unique options while editing a field
  • Object descriptions are displayed with word wrap now
  • Fixed a bug with displaying query results in Query Data with some definite settings enabled
  • A bug with the "SQL Monitor Options" button in SQL Monitor is fixed
  • Now you can set names longer than 31 characters for all the objects on server 7.3
  • In the Form View of the Results tab in Design Query and Query Data fields are no more available for editing for non-alive queries
  • The Returns drop-down list in Function Editor now contains complex types (i.e., table's row types)
  • View Editor for server 7.3: Now on renaming a view or one of the view's columns the update script is generated as CREATE OR REPLACE VIEW, instead of DROP - CREATE VIEW
  • Fixed a bug with impossibility of entering some specific characters in the code editors with AltGr
  • Object comments which contain an apostrophe (') symbol are now saved correctly
  • Fixed a bug with loading visual settings on program startup
  • Fixed a bug with adding SERIAL and BIGSERIAL fields to a table
  • A lot of other bug-fixes and small improvements

Scroll to top

Version 1.2.0.1

  • Full PostgreSQL server v7.3 support
  • Name space support: Now a box for setting object name space is added to each object editor, and database objects in the DB Explorer tree and in all object editor trees are divided by schemas. You can create, edit and drop database schemas in the same way as other objects via DB Explorer
  • Domains added to the DB Explorer tree. Use Domain Editor to create and edit domains
  • Grant Manager allows setting privileges for Databases, Functions, Schemas, and Languages
  • Index list moved to the main tree, like triggers and rules, and the Index Editor window is no more modal
  • German and Russian localizations added. Select the Options | Select Program Language main menu item to change the program interface language
  • Grant Manager now allows setting privileges for the PUBLIC group
  • Now you can select objects to expand automatically in the DB Explorer on connect to the database. Use the Tools | DB Explorer page of the Environment Options dialog for this purpose
  • Fixed bug in connecting to a database, if it contains two objects in one name space with names differing only by their case
  • Fixed bug in connecting to a database, if it contains views with spaces in their names
  • A lot of other bug-fixes and small improvements

Scroll to top

Version 1.1.0.1

  • Now PostgreSQL Manager supports the PostgreSQL server v7.3!
  • Function Editor: The 'Is Cachable' option is gone, the new option 'Execute with definer's privileges' and the new switch 'Replace multiple calls with single on same arguments' added
  • Type Editor: Boxes 'External Length', 'Send Function' and 'Receive Function' disappeared
  • Operator Editor: New fields 'Less Than Operator', 'Greater Than Operator' and 'Support merge joins' added
  • Language Editor: The 'Validation Function' drop-down list appeared
  • Options 'Is Cachable' and 'Is Strict' in Function Editor were renamed into 'Returns same result on same arguments' and 'Returns null on null input' respectively
  • The array types, which names begin with '_' are excluded from the DB Explorer object tree
  • Fixed bug with granting privileges to groups
  • When 'Grant All' is performed in Grant Manager, the Owner privilege is not granted, as it was in previous versions
  • No error message appears now if on saving an index the 'Rollback' button is clicked
  • Fixed an error with decreasing of the connection speed if the database contains rules and triggers and system objects are not displayed
  • Several improvements and small bug-fixes

Scroll to top

Version 1.0.0.1

  • The 'Services' menu added. It contains powerful wizards for executing native PostgreSQL services: Analyze Tables, Vacuum Tables, and Reindex
  • Service 'Analyze & Vacuum Table' is now available for each table. It can be called quickly from Table Editor
  • Interface localization is implemented. No languages are available yet, but you can create your own language file to localize the PostgreSQL Manager interface. Just press Shift+Ctrl+L within any window to call Localization Editor or create your own *.lng file based on the 'english.lng' file (see $(PostgreSQL Manager)\Languages folder to find it). We will be very grateful to anyone who send us a translation of 'english.lng' to his native language (we will provide each translator with a free PostgreSQL Manager copy)
  • The Design Query setting tab is added to the Environment Options window
  • A possibility of running multiple PostgreSQL Manager instances added. The 'Disable multiple instances' option appeared in the Environment Options window on the Preferences tab
  • The 'Show System Objects' option now applies to a database only, not to the whole application. This option is excluded from the Environment Options dialog and moved to the Register Database and Register Host dialogs
  • The 'Sort By Aliases' element of the DB Explorer popup menu now saves its value after restarting the application
  • The 'Confirm running selected query in Query Data' option is now excluded from the Environment Options dialog, the 'Execute selected text separately' option added to the Tools | Query Data tab instead
  • Fixed bug in generating the SQL statement in the Create Database Wizard
  • Several small improvements and minor bug-fixes

Scroll to top

First public release

Basic features:

  • Easy management of all database objects: creating/dropping databases, schemas; creating/dropping/altering tables and their subobjects, views, functions, sequences, rules, types, aggregates, operators, languages; etc.
  • Creating/dropping/altering all the table subobjects
  • Viewing/editing data in tables
  • Support of all PostgreSQL data types
  • Multiple database connections
  • Powerful User Manager, Group Manager and Grant Manager
  • Query Data with syntax highlight
  • Visual Design Query
  • Powerful BLOB Viewer/Editor that provides several ways of viewing BLOB data
  • Export data to 12 popular formats, including MS Access, Excel, RTF (Word), HTML, etc.
  • Import data from most popular formats, including MS Excel, Access, etc.
  • Load Data to/from the server
  • Customizable program interface
  • Detailed Help System and User's Guide

and more...

Scroll to top

See also:

What's new


EMS SQL Manager FAQ

Please read this page attentively if you have questions about EMS SQL Manager for PostgreSQL.

Table of contents

Product questions

  • What is EMS SQL Manager for PostgreSQL?
  • What is the difference between Full/Lite editions of EMS SQL Manager for PostgreSQL?
  • What do I need to start working with EMS SQL Manager for PostgreSQL?
  • What is the difference between the Export/Import functions in SQL Manager and the Data Export/Import utilities?
  • What is the difference between the Design Query module in SQL Manager and the SQL Query for PostgreSQL utility?
  • What is the difference between the Extract Database function in SQL Manager for PostgreSQL and the DB Extract for PostgreSQL standalone utility?

Common questions

  • I've registered the DB, but on attempt to open it the "dynamic library libpq.dll not found" message appears.
  • I can't modify DDL. Why?
  • How can I customize data formats in grid?
  • I need to perform some changes in database objects of my test database and then make the same changes on master database. Are there any tools for this purpose in SQL Manager for PostgreSQL?
  • When I create database objects, their names are always converted to lower case. How I can prevent it?
  • I am trying to create a report in Report Designer, but I can't get access to the table data: 'Band data source' list is empty.
  • How can I speed up my work with large tables?
  • I have a table with appr. 1000 records only, and a large number of columns. Opening this table on the 'Data' tab takes too much time.
  • I get error 'Timeout expired' when I try to execute a query in Query Data or when I perform some operations with database objects.

Export/Import questions

  • I'm trying to export data from a table, but TEXT columns are not exported.
  • What is the difference between the "Extract Database" and "Export as SQL Script" functions?
  • How can I change the default directory where exported data are saved?

Question/answer list

Product questions

Q: What is EMS SQL Manager for PostgreSQL?

A: EMS SQL Manager for PostgreSQL is a powerful tool for PostgreSQL database server administration and development. SQL Manager for PostgreSQL works with any PostgreSQL versions up to 16 and supports all of the latest PostgreSQL features. It offers plenty of powerful tools for experienced users to satisfy all their needs. SQL Manager for PostgreSQL has a new state-of-the-art graphical user interface with well-described wizard system, so clear in use that even a newbie will not be confused with it.

Q: What is the difference between Full/Lite editions of EMS SQL Manager for PostgreSQL?

A: These editions of SQL Manager for PostgreSQL differ in price and features. To register SQL Manager for PostgreSQL, see the Purchase page, and to learn about the difference in features please go to our Feature Matrix page.

Q: What do I need to start working with EMS SQL Manager for PostgreSQL?

A: First of all you must have a possibility to connect to some local or remote PostgreSQL server to work with SQL Manager for PostgreSQL. You can download PostgreSQL server from https://www.postgresql.org/downloads (download is free). Besides, you need your workstation to satisfy the system requirements of SQL Manager for PostgreSQL.

Q: What is the difference between the Export/Import functions in SQL Manager and the Data Export/Import utilities?

A: The Data Export/Import for PostgreSQL utilities include some additional features which are not available in SQL Manager, such as:

  • export/import data from/to several tables simultaneously;
  • export/import data from/to tables selected from different databases on one host;
  • a command-line utility to export/import data using the configuration file with all the export/import options.

Q: What is the difference between the Design Query module in SQL Manager and the SQL Query for PostgreSQL utility?

A: First of all, SQL Query for PostgreSQL works faster as it is a much lighter product. Besides, it provides additional features for query building, e.g.:

  • keeping query history which allows you to rollback to any edited query;
  • various interface improvements for more productive and easier work.

Q: What is the difference between the Extract Database function in SQL Manager for PostgreSQL and the DB Extract for PostgreSQL standalone utility?

A: The DB Extract for PostgreSQL utility includes some additional features which are not available in SQL Manager, such as:

  • extracting metadata and/or data from several databases on one host;
  • a console application for performing extract in one-touch;
  • faster extraction speed.

Scroll to top

Common questions

Q: I've registered the DB, but on attempt to open it the "dynamic library libpq.dll not found" message appears.

A: Please make sure that the libpq.dll file exists in the SQL Manager for PostgreSQL directory. Reinstallation of the application can solve the problem.

Q: I can't modify DDL. Why?

A: The DDL tab of the SQL Manager editors is read-only. It displays object structure as SQL text and reflects the operations you perform over the object under other editor tabs. To modify an object, you can copy the text to the clipboard and edit it using SQL Script Editor. For more details refer to Viewing object DDL structure.

Q: How can I customize data formats in grid?

A: You can customize all display formats: integer, float, date, time and datetime using the Color & Formats page of the Environment Options dialog.

Q: I need to perform some changes in database objects of my test database and then make the same changes on master database. Are there any tools for this purpose in SQL Manager for PostgreSQL?

A: The Database Registration Info dialog provides the Logs section where you can enable logging metadata changes performed over the database and/or SQL queries executed in Query Data.

Q: When I create database objects, their names are always converted to lower case. How I can prevent it?

A: Please try to switch off the "Convert created objects' names to lower case" option within the Object Editors section of the Environment Options dialog.

Q: I am trying to create a report in Report Designer, but I can't get access to the table data: 'Band data source' list is empty.

A: It is recommended to use Create Report wizard which is run by right-clicking the Reports node in DB Explorer and selecting the 'New Report...' context menu item. The wizard will create all necessary data sources.

If you still want to use Report Designer, to get the data source in a report, you need to add database and query components to the report.

Q: How can I speed up my work with large tables?

A: For your convenience and to speed up your work, the Data Grid allows customizing a number of data display parameters. Here are the most important of them (accessible through the Grid | Data Options section of the Environment Options dialog):
- Limit options in table and view editors. The 'Select all records of a table' option will enable you to see all table records without extra references to the server, yet in case of large tables or low speed connection channel the data may be fetched with huge delays and the incoming traffic might grow considerably. This mode is recommended when working with local databases or in a private network. The 'Select only' mode restricts the maximum number of records returned after the query. A man cannot process a massive amount of information at once. Hence, we came up with this mode. This mode speeds up table data viewing considerably, prevents hanging and connection timeout. It is recommended to work with large tables, in case of low speed connection channels and when the traffic volume is of importance. This is the default mode. When in this mode, enabling the 'Use SQL sorting in data view' and 'Use SQL filter in data view' options comes really helpful.
- Default Grid Mode. This option defines whether the requested rows will be loaded in the Grid all at once ('Load all rows'), or in parts ('Load visible rows') as the user scrolls down table data. The first mode increases the query opening time, but speeds up scrolling. In the second mode the query opens very fast, but there might be delays when navigating the grid.
We recommend that you set the following option values to achieve maximum efficiency when working with large tables:
- Select only – ON
- Load visible rows – ON

Q: I have a table with appr. 1000 records only, and a large number of columns. Opening this table on the 'Data' tab takes too much time.

A: You need to set the Grid Mode for the table to 'Load Visible Rows'. Please right click within the table grid and select the 'Grid Mode' | 'Load Visible Rows' context menu item.

Q: I get error 'Timeout expired' when I try to execute a query in Query Data or when I perform some operations with database objects.

A: You need to increase timeout values within the Tools | Timeouts section of the Environment Options dialog, or set them to 0 (unlimited).

Scroll to top

Export/Import questions

Q: I'm trying to export data from a table, but TEXT columns are not exported.

A: Columns of type TEXT are not exported by default. You should select these columns manually at the Selecting columns for export step.

Q: What is the difference between the "Extract Database" and "Export as SQL Script" functions?

A: Export as SQL Script is intended for exporting table data that will be inserted into a database system other than PostgreSQL. Use Extract Database Wizard to copy metadata and/or data to a database on PostgreSQL afterwards.

Q: How can I change the default directory where exported data are saved?

A: Follow the steps below to change the default directory:

1. Right-click the database alias in DB Explorer and select the 'Database Registration Info...' context menu item (you can also find this item in the 'Database' main menu) to open the Database Registration Info dialog.

2. Proceed to the Directories section within the dialog.

3. Set the 'Default directory for Export Data'.

Scroll to top

If you still have any questions, contact us at our Support Center.


Other EMS Products

Quick navigation

MySQL

Microsoft SQL Server

PostgreSQL

InterBase / FireBird

Oracle

IBM DB2

Tools & components

MySQL

 | SQL Management Studio for MySQL EMS SQL Management Studio for MySQL is a complete solution for database administration and development. SQL Studio unites the must-have tools in one powerful and easy-to-use environment that will make you more productive than ever before!
 | SQL Manager for MySQL Simplify and automate your database development process, design, explore and maintain existing databases, build compound SQL query statements, manage database user rights and manipulate data in different ways.
dataexport | Data Export for MySQL Export your data to any of 20 most popular data formats, including MS Access, MS Excel, MS Word, PDF, HTML and more.
dataimport | Data Import for MySQL Import your data from MS Access, MS Excel and other popular formats to database tables via user-friendly wizard interface.
datapump | Data Pump for MySQL Migrate from most popular databases (MySQL, PostgreSQL, Oracle, DB2, InterBase/Firebird, etc.) to MySQL.
datagenerator | Data Generator for MySQL Generate test data for database testing purposes in a simple and direct way. Wide range of data generation parameters.
dbcomparer | DB Comparer for MySQL Compare and synchronize the structure of your databases. Move changes on your development database to production with ease.
extract | DB Extract for MySQL Create database backups in the form of SQL scripts, save your database structure and table data as a whole or partially.
query | SQL Query for MySQL Analyze and retrieve your data, build your queries visually, work with query plans, build charts based on retrieved data quickly and more.
datacomparer | Data Comparer for MySQL Compare and synchronize the contents of your databases. Automate your data migrations from development to production database.
 | Scroll to top

Microsoft SQL Server

 | SQL Management Studio for SQL Server EMS SQL Management Studio for SQL Server is a complete solution for database administration and development. SQL Studio unites the must-have tools in one powerful and easy-to-use environment that will make you more productive than ever before!
 | EMS SQL Backup for SQL Server Perform backup and restore, log shipping and many other regular maintenance tasks on the whole set of SQL Servers in your company.
sqladmin | SQL Administrator for SQL Server Perform administrative tasks in the fastest, easiest and most efficient way. Manage maintenance tasks, monitor their performance schedule, frequency and the last execution result.
 | SQL Manager for SQL Server Simplify and automate your database development process, design, explore and maintain existing databases, build compound SQL query statements, manage database user rights and manipulate data in different ways.
dataexport | Data Export for SQL Server Export your data to any of 20 most popular data formats, including MS Access, MS Excel, MS Word, PDF, HTML and more
dataimport | Data Import for SQL Server Import your data from MS Access, MS Excel and other popular formats to database tables via user-friendly wizard interface.
datapump | Data Pump for SQL Server Migrate from most popular databases (MySQL, PostgreSQL, Oracle, DB2, InterBase/Firebird, etc.) to Microsoft® SQL Server™.
datagenerator | Data Generator for SQL Server Generate test data for database testing purposes in a simple and direct way. Wide range of data generation parameters.
dbcomparer | DB Comparer for SQL Server Compare and synchronize the structure of your databases. Move changes on your development database to production with ease.
extract | DB Extract for SQL Server Create database backups in the form of SQL scripts, save your database structure and table data as a whole or partially.
query | SQL Query for SQL Server Analyze and retrieve your data, build your queries visually, work with query plans, build charts based on retrieved data quickly and more.
datacomparer | Data Comparer for SQL Server Compare and synchronize the contents of your databases. Automate your data migrations from development to production database.
 | Scroll to top

PostgreSQL

 | SQL Management Studio for PostgreSQL EMS SQL Management Studio for PostgreSQL is a complete solution for database administration and development. SQL Studio unites the must-have tools in one powerful and easy-to-use environment that will make you more productive than ever before!
 | EMS SQL Backup for PostgreSQL Creates backups for multiple PostgreSQL servers from a single console. You can use automatic backup tasks with advanced schedules and store them in local or remote folders or cloud storages
 | SQL Manager for PostgreSQL Simplify and automate your database development process, design, explore and maintain existing databases, build compound SQL query statements, manage database user rights and manipulate data in different ways.
dataexport | Data Export for PostgreSQL Export your data to any of 20 most popular data formats, including MS Access, MS Excel, MS Word, PDF, HTML and more
dataimport | Data Import for PostgreSQL Import your data from MS Access, MS Excel and other popular formats to database tables via user-friendly wizard interface.
datapump | Data Pump for PostgreSQL Migrate from most popular databases (MySQL, SQL Server, Oracle, DB2, InterBase/Firebird, etc.) to PostgreSQL.
datagenerator | Data Generator for PostgreSQL Generate test data for database testing purposes in a simple and direct way. Wide range of data generation parameters.
dbcomparer | DB Comparer for PostgreSQL Compare and synchronize the structure of your databases. Move changes on your development database to production with ease.
extract | DB Extract for PostgreSQL Create database backups in the form of SQL scripts, save your database structure and table data as a whole or partially.
query | SQL Query for PostgreSQL Analyze and retrieve your data, build your queries visually, work with query plans, build charts based on retrieved data quickly and more.
datacomparer | Data Comparer for PostgreSQL Compare and synchronize the contents of your databases. Automate your data migrations from development to production database.
 | Scroll to top

InterBase / Firebird

 | SQL Management Studio for InterBase/Firebird EMS SQL Management Studio for InterBase and Firebird is a complete solution for database administration and development. SQL Studio unites the must-have tools in one powerful and easy-to-use environment that will make you more productive than ever before!
 | SQL Manager for InterBase/Firebird Simplify and automate your database development process, design, explore and maintain existing databases, build compound SQL query statements, manage database user rights and manipulate data in different ways.
dataexport | Data Export for InterBase/Firebird Export your data to any of 20 most popular data formats, including MS Access, MS Excel, MS Word, PDF, HTML and more
dataimport | Data Import for InterBase/Firebird Import your data from MS Access, MS Excel and other popular formats to database tables via user-friendly wizard interface.
datapump | Data Pump for InterBase/Firebird Migrate from most popular databases (MySQL, SQL Server, Oracle, DB2, PostgreSQL, etc.) to InterBase/Firebird.
datagenerator | Data Generator for InterBase/Firebird Generate test data for database testing purposes in a simple and direct way. Wide range of data generation parameters.
dbcomparer | DB Comparer for InterBase/Firebird Compare and synchronize the structure of your databases. Move changes on your development database to production with ease.
extract | DB Extract for InterBase/Firebird Create database backups in the form of SQL scripts, save your database structure and table data as a whole or partially.
query | SQL Query for InterBase/Firebird Analyze and retrieve your data, build your queries visually, work with query plans, build charts based on retrieved data quickly and more.
datacomparer | Data Comparer for InterBase/Firebird Compare and synchronize the contents of your databases. Automate your data migrations from development to production database.
 | Scroll to top

Oracle

 | SQL Management Studio for Oracle EMS SQL Management Studio for Oracle is a complete solution for database administration and development. SQL Studio unites the must-have tools in one powerful and easy-to-use environment that will make you more productive than ever before!
 | SQL Manager for Oracle Simplify and automate your database development process, design, explore and maintain existing databases, build compound SQL query statements, manage database user rights and manipulate data in different ways.
dataexport | Data Export for Oracle Export your data to any of 20 most popular data formats, including MS Access, MS Excel, MS Word, PDF, HTML and more.
dataimport | Data Import for Oracle Import your data from MS Access, MS Excel and other popular formats to database tables via user-friendly wizard interface.
datapump | Data Pump for Oracle Migrate from most popular databases (MySQL, PostgreSQL, MySQL, DB2, InterBase/Firebird, etc.) to Oracle
datagenerator | Data Generator for Oracle Generate test data for database testing purposes in a simple and direct way. Wide range of data generation parameters.
dbcomparer | DB Comparer for Oracle Compare and synchronize the structure of your databases. Move changes on your development database to production with ease.
extract | DB Extract for Oracle Create database backups in the form of SQL scripts, save your database structure and table data as a whole or partially.
query | SQL Query for Oracle Analyze and retrieve your data, build your queries visually, work with query plans, build charts based on retrieved data quickly and more.
datacomparer | Data Comparer for Oracle Compare and synchronize the contents of your databases. Automate your data migrations from development to production database.
 | Scroll to top

IBM DB2

 | SQL Manager for DB2 Simplify and automate your database development process, design, explore and maintain existing databases, build compound SQL query statements, manage database user rights and manipulate data in different ways.
dataexport | Data Export for DB2 Export your data to any of 20 most popular data formats, including MS Access, MS Excel, MS Word, PDF, HTML and more.
dataimport | Data Import for DB2 Import your data from MS Access, MS Excel and other popular formats to database tables via user-friendly wizard interface.
datapump | Data Pump for DB2 Migrate from most popular databases (MySQL, PostgreSQL, Oracle, MySQL, InterBase/Firebird, etc.) to DB2
datagenerator | Data Generator for DB2 Generate test data for database testing purposes in a simple and direct way. Wide range of data generation parameters.
extract | DB Extract for DB2 Create database backups in the form of SQL scripts, save your database structure and table data as a whole or partially.
query | SQL Query for DB2 Analyze and retrieve your data, build your queries visually, work with query plans, build charts based on retrieved data quickly and more.
 | Scroll to top

Tools & components

advancedexport | Advanced Data Export for RAD Studio VCL Advanced Data Export for RAD Studio VCL allows you to save your data in the most popular office programs formats.
advancedexport | Advanced Data Export .NET Advanced Data Export .NET is a component for Microsoft Visual Studio .NET that will allow you to save your data in the most popular data formats for the future viewing, modification, printing or web publication. You can export data into MS Access, MS Excel, MS Word (RTF), PDF, TXT, DBF, CSV and more! There will be no need to waste your time on tiresome data conversion - Advanced Data Export will do the task quickly and will give the result in the desired format.
advancedimport | Advanced Data Import for RAD Studio VCL Advanced Data Import for RAD Studio VCL will allow you to import your data to the database from files in the most popular data formats.
pdfgenerator | Advanced PDF Generator for RAD Studio Advanced PDF Generator for RAD Studio gives you an opportunity to create PDF documents with your applications written on Delphi or C++ Builder.
querybuilder | Advanced Query Builder for RAD Studio VCL Advanced Query Builder for RAD Studio VCL is a powerful component for Delphi and C++ Builder intended for visual building SQL statements for the SELECT, INSERT, UPDATE and DELETE clauses.
excelreport | Advanced Excel Report for RAD Studio Advanced Excel Report for RAD Studio is a powerful band-oriented generator of template-based reports in MS Excel.
advancedlocalizer | Advanced Localizer for RAD Studio VCL Advanced Localizer for RAD Studio VCL is an indispensable component for Delphi for adding multilingual support to your applications.
 | Scroll to top


Getting Started

SQL Manager for PostgreSQL provides you with an ability to contribute to efficient PostgreSQL administration and development using a variety of available tools easily and quickly.

The succeeding chapters of this document are intended to inform you about the tools implemented in SQL Manager for PostgreSQL. Please see the instructions below to learn how to perform various operations in the easiest way.

  • Selecting style and language
  • How the application looks when you start it for the first time
  • Using Desktop Panel
  • Database navigation
  • Working with database objects
  • Using context menus
  • Working with child windows

See the How to... chapter to view brief instructions on how to perform some operations on databases, database objects, etc.

Enjoy your work with EMS SQL Manager for PostgreSQL!

See also:

Database Explorer

Database Management

Database Objects Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Database Tools

Services

Options

How To...


Selecting style and language

SQL Manager for PostgreSQL
  • Index
  • « Prev
  • Next »

Selecting environment style and program language

Before you start SQL Manager for the first time, you have to choose the appearance style and the interface language. You can change these settings any time using the Environment Options dialog to configure environment style and the language.

Appearance theme

Select the main color theme for the application: Light, Blue or Dark.

Bar style for editors

Here you can define the location of action buttons: RadioButton within the Navigation bar (on the left) and/or RadioButton on the Toolbar.

Program language

Select the interface language from the list of available languages.

Sample

See the example of selected options for interface.

Getting started - Selecting style and language

See also:

First time started

Using Desktop Panel

Database navigation

Working with database objects

Using context menus

Working with windows


First time started

This is how SQL Manager for PostgreSQL looks when you start it for the first time. Use the Desktop panel to fulfill any of common tasks: Create a new database, Manage existing database(s), and several tasks that do not require database registration, i.e. Execute script, accessing the reference system or using available Internet resources.

The main menu allows you to perform various Database operations, open To-Do List and activate/deactivate Database Explorer, SQL Assistant and various toolbars within the View menu, manage your databases using items of the Tools and Services menus, customize the application using the Options menu, manage SQL Manager Windows using Window List and other tools, access Registration information and product documentation, update the product to the latest version using the corresponding items available within the Help menu.

To start working with your PostgreSQL server, you should first register one or several databases using Register Database Wizard.

By default the corresponding btnRegisterDB Register Database button is available on the toolbar and within the Database menu.

When the database connection settings are specified, you can set connection to your database and proceed to Database navigation, Database Objects management, working with SQL queries and other tools of SQL Manager.

Getting started - First time started

See also:

Selecting style and language

Using Desktop Panel

Database navigation

Working with database objects

Using context menus

Working with windows


Using Desktop Panel

Desktop Panel is the area that is visible when no child windows are open in SQL Manager for PostgreSQL. The working area of Desktop Panel is divided into four sections: Getting Started, Database Tools, Help and Support, Internet Resources.

Getting started - Using Desktop Panel

Using the Desktop Panel items you can:

Getting Started

create a new PostgreSQL database

register existing database(s) to operate them afterwards in SQL Manager

create a new table within the current database using the New Table window (this item is available if there is at least one active database connection)

create a new database object within the current database (this item is available if there is at least one active database connection)

Database Tools

execute a script using SQL Script Editor

execute a SQL query (this item is available if there is at least one active database connection)

grant permissions on database objects to PostgreSQL users using Grant Manager (this item is available if there is at least one active database connection)

Help and Support

show this help file

use PostgreSQL reference

Internet Resources

visit SQL Manager Home Page

browse SQL Manager on-line documentation

go to Technical Support Center

look through the Frequently Asked Questions page

See also:

Selecting style and language

First time started

Database navigation

Working with database objects

Using context menus

Working with windows


Database navigation

After you have registered the required database(s), the corresponding alias(es) appear in the DB Explorer tree on the left. If the Show Hosts option is checked on the Environment Options | DB Explorer page, the host nodes are also displayed in the tree (alternatively, you can use the Show Hosts item of the Database context menu, or the drop-down menu of the View Mode btnViewMode toolbar button for the same purpose). If necessary, you can also specify that empty schemas should be hidden in the tree: use the corresponding option available on the DB Explorer page of the Environment Options dialog.

Getting started - Database navigation

DB Explorer displays all registered databases. Connected/disconnected databases can be easily distinguished in the tree: aliases of disconnected databases are grayed out.

Getting started - Database navigation - Disconnected DB

To connect to a database, simply double-click its alias (or select the database alias in DB Explorer and press Enter). If the connection is successful, the database node expands into a tree of objects. To select the types of objects to be expanded upon successful database connection, you can use the Expand after connection group of the Environment Options | DB Explorer page.

Now you can navigate within the database objects. Use SQL Assistant to get extended information about the currently selected object.

See also:

Selecting style and language

First time started

Using Desktop Panel

Working with database objects

Using context menus

Working with windows


Working with database objects

The nodes of the DB Explorer tree allow you to access objects of the selected database. If PostgreSQL server you are connected to supports certain types of objects, their nodes will appear in the tree.

Double-click an object group to expand/collapse the corresponding tree node.

Double-click an object to open it in the corresponding editor.

Right-click an object to display its context menu which allows you to perform various operations over the selected object or database.

Getting started - Working with database objects

If you want to use the DB Explorer tree for working with table subobjects (columns, indexes, Foreign keys, etc.), check the Show table subobjects option which is available within the General options group of the Environment Options | DB Explorer page (you can also use the Show Table Subobjects menu item in the drop-down menu of the View Mode btnViewMode toolbar button for the same purpose.)

Getting started - Working with database objects - View Mode

See also:

Selecting style and language

First time started

Using Desktop Panel

Database navigation

Using context menus

Working with windows


Using context menus

The context menus are aimed at facilitating your work with SQL Manager for PostgreSQL: you can perform a variety of operations using context menu items.

Select an object in DB Explorer and right-click its alias to open the context menu.

  • Host context menu
  • Database context menu
  • Object context menu

See also:

Selecting style and language

First time started

Using Desktop Panel

Database navigation

Working with database objects

Working with windows


Host context menu

The context menu of a host in the DB Explorer tree allows you to:

  • access services and principals within the Tasks submenu
  • launch iconChangeManagement Change management tools
  • define host connection settings in the Server Configuration dialog
  • create database using the btnCreateDB Create Database Wizard
  • register a new database using the btnRegisterDB Register Database Wizard
  • btnUnregisterHost unregister the selected host
  • manage databases registration
  • access iconViewMode View Mode options
  • manage DB Explorer Tabs
  • search for database objects using iconFindObject Find Object dialog
  • continue searching for database objects that match the defined conditions.

Using context menus - Host context menu

Tasks

  • check iconServerStatus server status within the corresponding dialog
  • manage iconUserManager user privileges
  • manage btnGroupManager user groups and their privileges
  • backup database using the wizard
  • restore database using the wizard.

Change Management

  • iconChange Management - Create branch-Label-Tag create branch/label/tag using the wizard
  • check repository using the wizard
  • iconChange Management - Get Change script get change script using the wizard
  • release new version of database using wizard
  • browse iconChange Management - History history of object/database changes.

View Mode

  • show/hide table subobjects
  • btnHost show/hide hosts
  • sort databases by their aliases (by default databases are displayed due to their registration order)
  • show/hide disconnected databases
  • check table subobjects to display in SQL Assistant within the Tables' Details submenu
  • check other subobjects to display in SQL Assistant within the Objects' Details submenu.

Tabs

  • btnNewTabFromHere create a new DB Explorer tab with the selected database/host only
  • rename active tab
  • delete active tab.

See also:

Database context menu

Object context menu


Database context menu

The context menu of a registered database in the DB Explorer tree allows you to:

  • btnConnectToDB connect to the selected database (if connection to the database is not active yet);
  • btnDisconnectFromDB disconnect from the selected database (if connection to the database has been already activated);
  • access database tools and services available in the Tasks submenu;
  • access iconChangeManagement change management tools;
  • view/edit the btnDBProperties Database properties;
  • view/edit the host properties within the Server Configuration dialog;
  • btnCreateDB create a new database at the host where the selected database resides;
  • iconDropDatabase drop the selected database;
  • view/edit the selected database registration information within the Database registration manager;
  • register a new database or host using btnRegisterDB Register Database Wizard;
  • btnUnregisterDB unregister the selected database;
  • btnUnregisterHost unregister the host where the selected database resides;
  • view/edit the selected database registration information within the btnDBRegistrationInfo Database Registration Info dialog;
  • generate the database script and open it in Query Data;
  • generate the database script and copy its text to Windows clipboard;
  • access iconViewMode View Mode options;
  • configure representation of hosts and databases in Database Explorer;
  • iconRefresh refresh the selected database;
  • test connection to the database (or reconnect if connection has been already established);
  • manage DB Explorer Tabs;
  • iconFindObject search for an object within the tree;
  • continue searching for database objects that match the defined conditions.

Using context menus - Database context menu

Tasks submenu allows you to:

backup database using the wizard

restore database using the wizard

btnGrantManager manage privileges

btnExtractDB extract database objects and/or data to an SQL script

iconDatabases copy database objects and data to different location

btnPrintMetadata print metadata

generate html report of the selected objects

iconToDoList create to-do list

analyze tables

vacuum tables

reindex database

database extensions

database statistics

Change Management submenu allows you to:

  • iconChange Management - Create branch-Label-Tag create branch/label/tag using the wizard
  • check repository using the wizard
  • iconChange Management - Get Change script get change script using the wizard
  • release new version of database using wizard
  • browse iconChange Management - History history of object/database changes

View Mode submenu allows you to:

  • show/hide table subobjects
  • btnHost show/hide hosts
  • sort databases by their aliases (by default databases are displayed due to their registration order)
  • show/hide disconnected databases
  • check table subobjects to display in SQL Assistant within the Tables' Details submenu
  • check other subobjects to display in SQL Assistant within the Objects' Details submenu

Tabs submenu allows you to:

  • create a new DB Explorer tab with the selected database/host only
  • rename active tab
  • delete active tab.

See also:

Host context menu

Object context menu


Object context menu

The context menu of an object (e.g. table or view) in the DB Explorer tree allows you to:

  • create a new database object of the same type;
  • edit the selected object in its editor;
  • rename the selected object;
  • drop the selected object from the database;
  • iconDuplicateObject duplicate the selected object (create a new object with the same DDL structure and properties as the selected object has);
  • access common Tasks applied to this object;
  • perform data manipulation operations (for tables and views);
  • access iconChangeManagement change management features;
  • view btnDBProperties properties (for tables);
  • define btnGrantManager grants for the selected object;
  • generate the object script and open it in Query Data;
  • generate the object script and copy its text to Windows clipboard;
  • iconRefresh refresh all objects of the selected object type;
  • view/edit the database registration information within the btnDBRegistrationInfo Database Registration Info dialog.
  • btnNewTabFromHere create a new tab for the selected object to access it through this tab quickly and/or manage the existing tab;
  • iconFindObject search for an object within the tree.

Using context menus - Object context menu

See also:

Host context menu

Database context menu


Working with windows

The Windows Toolbar of SQL Manager allows you to switch between child windows easily, like in Windows Task Bar.

To activate the window you need, simply click one of the window buttons. To perform some additional actions with the window, right-click its tab and select the corresponding menu item from the popup menu.

Getting started - Switching windows

If you have multiple windows opened, you can also switch between them using the Ctrl+Tab shortcut.

The Number of open editors is restricted option available in the Windows section of the Environment Options options dialog allows you to set the maximum number of editors that may be opened simultaneously. When the number of editors exceeds the specified value, the previously opened editors will be closed automatically.

The Windows menu facilitates your work with SQL Manager windows.

The Windows menu allows you to:

  • view the Windows List within the corresponding tab of DB Explorer;
  • set all current windows cascade:

Getting started - Windows - Cascade

  • minimize all windows;
  • restore all windows;
  • tile all current windows horizontally:

Getting started - Windows - Tile Horizontal

  • tile all current windows vertically:

Getting started - Windows - Tile Vertical

  • set defaults to all windows;
  • reset all toolbars and menus;
  • close all windows;
  • close all database windows (closes all windows owned by the database selected in the windows list);
  • close all editors of the specified object type (can be selected from the submenu);
  • switch to the previous window;
  • switch to the next window;
  • activate one of currently opened windows.

See also:

Selecting style and language

First time started

Using Desktop Panel

Database navigation

Working with database objects

Using context menus


Database Explorer

Database Explorer (or DB Explorer) is the basic window of SQL Manager for PostgreSQL for navigation within databases and working with database objects. The tree-like structure of DB Explorer allows you to manage the databases and database objects, and perform other everyday operations quickly and easily.

The following list contains the most frequently used features provided by Database Explorer.

  • Managing database registration info
  • Connecting to databases
  • Performing basic operations upon database objects
  • Selecting multiple objects
  • Navigating database objects using multiple tabs
  • Easy access to recently opened objects
  • Searching within the tree
  • Viewing extended information about database objects
  • Configuring Database Explorer
  • Managing Favorite queries

All objects are structured by their types and are available within the corresponding nodes of the tree. The number of objects of each type is displayed in brackets after the node name denoting the object type. To expand/collapse a node, you can double-click it or use the +/- icons.

To view/hide the Database Explorer window, use the View | DB Explorer main menu item or press the F11 key.

DB Explorer - View

Use the Ctrl+Shift+C shortcut to collapse the current DB Explorer tree branch and switch to the parent node.

Note that you can change database aliases order by dragging them within the DB Explorer tree.

See also:

Getting Started

Database Management

Database Objects Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Database Tools

Services

Options

How To...


Managing database registration info

After you have created and/or registered your database in SQL Manager for PostgreSQL, you can perform a number of operations with the database using the context menu.

If you need to view/edit the registration information of a database, right-click the database alias in DB Explorer and select the Database Registration Info... context menu item to open the Database Registration Info dialog.

See also:

Register Database

Database Registration Info

Database Registration Manager


Connecting to databases

When the database registration is complete, you can establish connection to your database.

The simplest way to connect to a database is to double-click its alias in the Database Explorer tree. The same operation can be performed by selecting the Connect to Database item of the database alias context menu, or by using the Database | Connect to Database main menu item.

DB Explorer - Connecting to databases

Alternatively, you can use the Shift+Ctrl+C shortcut or the btnConnectToDB Connect to Database toolbar button.

DB Explorer - Connecting to databases - Toolbar

See also:

Register Database

Database Registration Info


Operations with database objects

Database Explorer allows you to perform various operations with database objects.

To open an object in its editor, you can double-click the object in the DB Explorer tree.

You can also right-click an object within the DB Explorer tree and use its context menu to perform a number of operations:

  • create a new object (the New <object>... item);
  • edit currently selected object (the Edit <object_name>... item);
  • rename currently selected object (the Rename <object_name>... item);
  • drop the selected object from the database (the Drop <object_name>... item);
  • duplicate the selected object (the Duplicate <object_name>... item);
  • define grants for the selected object (the Grants for <object_name>... item).

Note that the context menu contains object-specific items only when the object is currently selected in DB Explorer.

DB Explorer - Operations with database objects

Using drag-and-drop operations you can add objects to Query Data, Design Query or Execute Script Editor. For your convenience the Insert to editor dialog is implemented. The dialog allows you to specify the statement to be inserted into the editor: Name, SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, columns list, Name and Type. If necessary, set the Alias and Prefix for variable.

If more convenient, you can edit the generated statement manually (see Working with Query Data area).

DB Explorer - Insert to Editor

See also:

Database Objects Management

Query Data

Selecting multiple objects


Selecting multiple objects

You can select more than one object in Database Explorer by pressing the Ctrl or the Shift key and selecting multiple objects one by one.

The context menu of several selected objects allows you to:

  • create a new database object of the same type;
  • edit the selected objects;
  • drop the selected objects;
  • perform other operations with the current object (see Operations with database objects).

DB Explorer - Selecting multiple objects

Hint: You can move several objects to your projects: just drag and drop the selected objects to the previously created subfolder within the Projects node of DB Explorer.

See also:

Operations with database objects

Database Objects Management

Managing projects


Using tabs for database navigation

To make your work with Database Explorer even more convenient, the capability of working with several tabs is implemented.

You can use tabs when you wish to work with a particular node of the DB Explorer tree only: with one specific schema, or with tables of some schema, or with a specific database project. Creating such tabs will minimize scrolling within large trees, you only need to switch between them with a single click on the corresponding tab.

Creating tabs

In order to create a new tab:

  • right-click the node (e.g. the Tables node) for which you wish to create a tab and select the New Tab from Here... context menu item.

Note: A tab can be created only on the basis of a tree node. For example, if the Show Table Subobjects option is disabled in the View Mode menu, the New Tab from Here... item will not be available for tables, since none of them will be a tree node anymore.

DB Explorer - Using tabs - New tab

The specified tabs can be displayed in either of the two views:

  • as icons on the lower pane of DB Explorer:

DB Explorer - Using tabs - View as icons

  • as tabs with captions:

DB Explorer - Using tabs - View as tabs

Hint: You can reorder items in the tabs view by dragging their captions up and down.

To add/remove items to/from the tabs view, you can drag the horizontal splitter up/down:

DB Explorer - Splitter for tabs

or click the Configure buttons icon available in the bottom right corner of the DB Explorer window, and select Show More Buttons / Show Fewer Buttons / Add or Remove Buttons items from the popup menu.

DB Explorer - Using tabs - Add or remove buttons

Note: Navigation through the tabs is also possible with the help of the following shortcuts:

  • Ctrl+Shift+N - move to the next tab;
  • Ctrl+Shift+P - move to the previous tab.

Renaming tabs

In order to rename a tab:

  • switch to the tab by clicking its caption or icon (there can be only one active tab, and it is highlighted with a different color);
  • right-click within the DB Explorer area and select the Rename Current Tab... context menu item.

Removing tabs

In order to remove a tab:

  • switch to the tab by clicking its caption or icon (there can be only one active tab, and it is highlighted with a different color);
  • right-click within the DB Explorer area and select the Delete Current Tab context menu item.

See also:

Managing projects

Windows List

Database Objects Management


Recently opened objects

Use the btnRecentObjects Recent Objects button available on the DB Explorer toolbar to access the list of recently opened database objects (during the current session).

This list is common for all registered databases. Next to the object name the database name and the host/address are displayed. Select an object from this list to open it using its editor.

DB Explorer - Recently opened objects

To change the number of objects that are considered 'recent', select the Options | Environment Options main menu item, proceed to the Tools | DB Explorer section within the Environment Options dialog, and set the Recent objects count option value (see Environment Options for details).

See also:

Database Objects Management

Environment Options


Managing projects

Use the Projects node for each database to work with the selected objects of this database only. You can place any object from the database tree here.

You can also create a separate tab for your project. See Using tabs for database navigation section for details.

DB Explorer - Managing projects - New Subfolder

Creating project folders

In order to create a new folder:

  • create a folder (if necessary, you can create subfolders inside the project folder) by right-clicking the Projects node and selecting the New Sub Folder... context menu item;
  • enter the folder name within the New Folder dialog.

DB Explorer - Managing projects - Adding objects

Adding objects

In order to add a new object to the project folder:

  • extent the Projects node in DB Explorer;
  • drag an object (or multiple objects) from the database tree to the project folder

or

  • right-click the project folder and select the Add Object... context menu item, or use the Ins key;
  • use the Select Object dialog to specify objects to be added to the project folder.

Removing objects from the project

In order to remove an object from the project:

  • right-click the object and select the Remove <object_name> from Project context menu item, or use the Shift+Ctrl+Del shortcut;
  • confirm removing in the dialog window.

Note: This operation does not drop the object from the database, but only removes its alias from the project tree.

See also:

Using tabs for database navigation

Select Object dialog

Database Objects Management


Searching within the tree

SQL Manager for PostgreSQL provides an ability to search for items within the DB Explorer tree. Searching for items may be useful if you have a lot of database objects, and it may be sometimes hard to find the one you need.

There are two search facilities implemented in SQL Manager for your convenience. You can search for objects within the DB Explorer tree in either of the following ways:

  • using the Find Object dialog

To call the Find Object dialog, right-click the Database alias, any database object group nodes or objects in the DB Explorer tree and select the Find Object... context menu item, or use the Ctrl+F shortcut.

DB Explorer - Find Object

Available search options are similar to those provided by the Find Text dialog. For detailed description of the search options refer to the Find Text dialog page.

Note: You can specify whether the search will be performed within the entire tree or within the currently selected node only: toggle search mode using the [image] Search by categories button on the Search Panel, or use the corresponding option available in the Tools | DB Explorer section of the Environment Options dialog.

  • using the Search Panel

Type in the first letters in the edit-box, and the corresponding object will be highlighted in the tree, as displayed in the picture below. The [image] [image] buttons allow you to define the search direction.

DB Explorer - Search Panel

By default, the Search Panel is activated in the upper area of DB Explorer. To disable the panel, right-click within the panel and deselect the checkbox at the corresponding popup menu item.

DB Explorer - Search Panel - Activate

The Search Panel also contains the button for switching the search mode which allows performing the search by object categories.

Hint: The Search Panel is dockable, i.e. you can drag it to any location within the DB Explorer form.

See also:

Find Text dialog


SQL Assistant

SQL Assistant which is located at the bottom of the Database Explorer window helps you to work with your database objects. Depending on the current selection in DB Explorer, the SQL Assistant area displays additional information pertaining to the selected object.

DB Explorer - SQL Assistant

If you select a host in DB Explorer, SQL Assistant displays the list of registered databases that reside on this host.

If you select a database in DB Explorer, SQL Assistant displays the list of the database object groups and the number of objects in each group.

If you select a schema in DB Explorer, SQL Assistant displays the schema definition (by default).

Selecting an object group in DB Explorer displays the list of the objects in SQL Assistant. Double-clicking the object name in SQL Assistant makes the object available for editing in the appropriate editor. The context menu of the object or group of objects (selected with the Ctrl or Shift keys pressed) allows you to edit or drop the selected objects.

If you select a table in DB Explorer, SQL Assistant displays the list of the table subobjects (e.g. columns and their types) by default. What is displayed in SQL Assistant when a table is selected in DB Explorer depends on the Table Details selection. Click the View Mode btnViewMode toolbar button and select the Table Details | Show... drop-down menu item, or use the context menu of SQL Assistant. Possible values are: Show Columns, Show Foreign Keys, Show Checks, Show Indexes, Show Triggers, Show Rules, Show Table Status, Show DDL, Show Description.

Selecting other objects in DB Explorer displays the definition in SQL Assistant by default. Use the Other Objects' Details | Show... context menu item within the SQL Assistant area to define the content of SQL Assistant when an object is selected in DB Explorer. Possible values are: Show DDL, Show Description.

DB Explorer - SQL Assistant - Object details

You can also use SQL Assistant to work with your queries quickly. You can drag-and-drop object aliases to the Query Data, Design Query or Execute Script Editor working area, in the same way as this operation is performed in Database Explorer.

See also:

Database Objects Management


Configuring Database Explorer

Configuring DB Explorer toolbar

The toolbar of Database Explorer contains most frequently used tools for working with databases and database objects, and a tool for configuring DB Explorer. The following actions are available in the toolbar by default:

  • create a new object;
  • refresh the current tree branch;
  • connect to a database;
  • disconnect from a database;
  • view the selected object properties;
  • configure Database Explorer using the View Mode menu;
  • view the list of recently opened objects;
  • jump to any of registered databases quickly.

Click More buttons... btnMoreButtons on the right side of the toolbar and use the Add or Remove Buttons popup menu items to define the set of actions available in the toolbar. To customize the toolbar, select the Add or Remove Buttons | Customize... item from the popup menu.

DB Explorer - Configuring DB Explorer - Toolbar

Configuring the Search Panel

Click More buttons... btnMoreButtons on the right side of the Search Panel and use the Add or Remove Buttons popup menu items to define the set of the panel elements. To customize the panel, select the Add or Remove Buttons | Customize... item from the popup menu.

DB Explorer - Search Panel - Customize

Using View Mode menu

Use the View Mode btnViewMode toolbar button to configure Database Explorer according to your needs.

The drop-down menu called upon clicking this button allows you to:

  • show/hide table subobjects as child nodes of tables;
  • show/hide host nodes for registered databases;
  • sort the list of databases by their aliases in the DB Explorer tree;
  • show/hide disconnected databases;
  • configure tables' details for the SQL Assistant area;
  • configure other objects' details for the SQL Assistant area.

DB Explorer - Configuring DB Explorer - View Mode

Use the DB Explorer section of the Environment Options dialog (Options | Environment Options...) to see more options to configure Database Explorer.

See also:

Database Objects Management


Managing Favorite queries

Favorite Queries is a new feature of SQL Manager. Now you are provided with an opportunity to save the most frequently used SQL queries as Favorite Queries.

Use the Favorite Queries node of DB Explorer to access the list of your Favorite queries quickly. Queries stored in the database and those stored in Windows registry can be easily distinguished by their icons.

Using the context menu you can create a new Favorite query or edit an existing one using Favorites editor, open any of the existing queries in Query Data or remove a query if you don't need it any longer.

DB Explorer - Managing Favorite queries

You can also create a separate tab for your Favorite queries. See Using tabs for database navigation section for details.

See also:

Using tabs for database navigation

Favorites editor


Database Management

SQL Manager for PostgreSQL provides a number of tools you may need to manage your PostgreSQL databases.

Find the list of common database management operations for working in SQL Manager below.

Unregistering host

In order to unregister a host in SQL Manager for PostgreSQL:

  • select the host to unregister in the DB Explorer tree, then select the Database | Unregister Host main menu item or use the corresponding btnUnregisterHost Unregister Host toolbar button;
  • right-click the host alias and select the Unregister Host context menu item in the DB Explorer tree;
  • confirm unregistering in the corresponding dialog window.

Creating database

In order to create a database in SQL Manager for PostgreSQL:

  • select the Database | Create Database main menu item or use the corresponding btnCreateDB Create Database toolbar button;
  • set all the necessary options using Create Database wizard which guides you through the entire process of creating a new database.

Dropping database

In order to drop a database in SQL Manager for PostgreSQL:

  • select the database to drop in the DB Explorer tree;
  • select the Database | Drop Database main menu item;
  • confirm dropping in the corresponding dialog window.

Registering database

In order to register a single database in SQL Manager for PostgreSQL:

  • select the Database | Register Database... main menu item or use the corresponding btnRegisterDB Register Database toolbar button;
  • right-click any database alias and select the Register Database... context menu item in the DB Explorer tree;
  • set all the necessary options using Register Database wizard which guides you through the entire process of database registration.

Unregistering database

In order to unregister a database in SQL Manager for PostgreSQL:

  • select the database to unregister in the DB Explorer tree, then select the Database | Unregister Database main menu item or use the corresponding btnUnregisterDB Unregister Database toolbar button;
  • right-click the database alias and select the Unregister Database context menu item in the DB Explorer tree;
  • confirm unregistering in the corresponding dialog window.

Connecting to database

In order to connect to a database in SQL Manager for PostgreSQL:

  • select the database to connect to in the DB Explorer tree, then select the Database | Connect to Database main menu item or use the corresponding btnConnectToDB Connect to Database toolbar button;
  • right-click the database alias and select the Connect to Database context menu item in the DB Explorer tree.

Disconnecting from database

In order to disconnect from a database in SQL Manager for PostgreSQL:

  • select the database to disconnect from in the DB Explorer tree, then select the Database | Disconnect from Database main menu item or use the corresponding btnDisconnectFromDB Disconnect from Database toolbar button;
  • right-click the database alias and select the Disconnect from Database context menu item in the DB Explorer tree.

Viewing and editing database registration info

In order to view/edit database registration info in SQL Manager for PostgreSQL:

  • select the database or any of its objects in the DB Explorer tree, then select the Database | Database Registration Info... main menu item;
  • right-click the database alias or any of its objects and select the Database Registration Info... context menu item in the DB Explorer tree.

Viewing and editing database properties

In order to view/edit database properties in SQL Manager for PostgreSQL:

  • select the database in the DB Explorer tree;
  • right-click the database alias and select the Database Properties... context menu item or use the corresponding btnDBProperties Properties toolbar button.

See also:

Getting Started

Database Explorer

Database Objects Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Database Tools

Services

Options

How To...


Create Database wizard

Create Database wizard allows you to create a new database on your PostgreSQL host.

To start the wizard, select the Database | Create Database... main menu item, or use the btnCreateDB Create Database button on the main toolbar.

  • Setting database name
  • Setting connection properties
  • Specifying tunneling parameters
  • Setting advanced database properties
  • Viewing result SQL statement

See also:

Register Database wizard

Database Registration Info

Database Properties


Setting database name

Use this step of the wizard to enter a name for the database being created.

Create Database Wizard - Setting database name

CheckBox Register after creating

Check this option to register the newly created database in SQL Manager (the Database Registration Info dialog will be opened after database creation).

Click the Next button to proceed to the Setting connection properties step of the wizard.


Setting connection properties

Use this step of the wizard to set the necessary connection parameters for the database being created. Use the corresponding boxes and options: Host name, Port, User name and Password.

Create Database Wizard - Setting connection properties

Specify the host where the database being created will reside: type in the host name in the Host name field or select one in the drop-down list.

Enter PostgreSQL port to connect through in the Port field and provide authorization settings: User name and Password.

CheckBox Use tunneling

If this option is checked, you should set tunneling parameters at the Specifying tunneling parameters step of the wizard.

Tunneling

RadioButton SSH tunneling

Select this option to establish connection to an intermediate SSH server and forward all PostgreSQL commands through the secure tunnel. The next step of the wizard allows you to define the corresponding parameters for SSH tunneling.

RadioButton HTTP tunneling

Select this option to access PostgreSQL server through the HTTP protocol in case of Internet access through HTTP proxy only, or if the server does not allow direct connections to PostgreSQL, but allows HTTP connections. The next step of the wizard allows you to define the corresponding parameters for HTTP tunneling.

Click the Next button to proceed to the Setting advanced database properties step of the wizard.


Specifying tunneling parameters

This step of the wizard allows you to specify the necessary parameters for connection with SSH or HTTP tunneling used.

SSH Tunneling parameters

Specify SSH Host name, SSH port, SSH user name, SSH password, the path to the SSH key file (if necessary) in the corresponding boxes.

See SSH connection properties for details.

Create Database Wizard - Setting connection properties - SSH

HTTP Tunneling parameters

If you have selected HTTP tunneling at the first step, you need to upload the tunneling emsproxy.php script to the webserver and specify the URL in the corresponding box in the following format: http://webserver_address/emsproxy.php

See HTTP connection properties for details.

Create Database Wizard - Setting connection properties - HTTP

Click the Next button to proceed to the Setting specific options step or to the Selecting databases step of the wizard, depending on whether the CheckBox Register a single database option has been selected or not.


Setting advanced database properties

This step of the wizard allows you to set advanced database properties for the new database.

Create Database Wizard - Setting advanced database properties

Location

Specify an alternate file system location in which the new database should be saved, specified as a literal string (for PostgreSQL 7.4 or lower).

Template

Use the drop-down list to select one of the existing databases on the host to indicate as a template for the database you create. Note that if you specified the template, your new database will contain all the data from the selected template.

Encoding

This option allows you to use multibyte encoding method in the new database. Use the drop-down list to select the required encoding value.

Owner

Use the drop-down list to select the name of the database user who will own the new database (for PostgreSQL 7.3 or higher). If no user is defined, then the currently connected user is used by default.

Default Tablespace

Use the drop-down list to set the default tablespace for objects of the database being created (for PostgreSQL 8.0 or higher).

Connection Limit

Specify the time limit (in milliseconds, use -1 for unlimited) for connecting to the new database (for PostgreSQL 8.1 or higher).

When you are done, click the Next button to view the result SQL statement.


Viewing result SQL statement

View the result CREATE DATABASE statement issued for the new database creation. You can alter the script manually, if necessary. For more information see Changing Metadata window.

Create Database Wizard - Viewing result SQL statement

If the CheckBox Register after creating option was checked at the Setting database name step of the wizard, the Database Registration Info dialog will appear.


Register Database wizard

Register Database Wizard allows you to register a single database.

To start the wizard, select the Database | Register Database... main menu item, or use the btnRegisterDB Register Database button on the main toolbar. You can also use the Shift+Alt+R shortcut for the same purpose.

  • Setting connection parameters
  • Specifying tunneling parameters
  • Selecting databases
  • Setting specific options

See also:

Create Database wizard

Database Registration Info

Database Properties


Setting connection parameters

Use this step of the wizard to set the necessary connection parameters for the new database/host using the corresponding boxes and options: Host name, Port, User name and Password.

Register Database wizard - Setting connection parameters

Specify the host you are going to work with: type in the host name in the Host name field or select one in the drop-down list.

Enter PostgreSQL port to connect through in the Port field and provide authorization settings: User name and Password.

CheckBox Register a single database

Check this option if you wish to register only one database at the host.

CheckBox Use tunneling

If this option is checked, you should set tunneling parameters at the Specifying tunneling parameters step of the wizard.

Tunneling

RadioButton SSH tunneling

Select this option to establish connection to an intermediate SSH server and forward all PostgreSQL commands through the secure tunnel. The next step of the wizard allows you to define the corresponding parameters for SSH tunneling.

RadioButton HTTP tunneling

Select this option to access PostgreSQL server through the HTTP protocol in case of Internet access through HTTP proxy only, or if the server does not allow direct connections to PostgreSQL, but allows HTTP connections. The next step of the wizard allows you to define the corresponding parameters for HTTP tunneling.

Click the Next button to proceed to the Setting specific options step or to the Selecting databases step of the wizard, depending on whether the CheckBox Register a single database option has been selected or not.


Specifying tunneling parameters

This step of the wizard allows you to specify the necessary parameters for connection with SSH or HTTP tunneling used.

SSH tunneling parameters

Specify SSH Host name, SSH port, SSH user name, SSH password, the path to the SSH key file (if necessary) in the corresponding boxes.

See SSH connection properties for details.

Register Database wizard - Setting connection parameters - SSH

HTTP tunneling parameters

If you have selected HTTP tunneling at the first step, you need to upload the tunneling emsproxy.php script to the webserver and specify the URL in the corresponding box in the following format: http://webserver_address/emsproxy.php

See HTTP connection properties for details.

Register Database wizard - Setting connection parameters - HTTP

Click the Next button to proceed to the Setting specific options step or to the Selecting databases step of the wizard, depending on whether the CheckBox Register a single database option has been selected or not.


Selecting databases

This step of the wizard allows you to select the database(s) that reside on the host for registration in SQL Manager.

To select a database, you need to move it from the Available databases list to the Selected databases list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the databases from one list to another.

Register Host Wizard - Selecting databases

If database is created by executing script in SQL Script editor then the Register Database dialog appears.

Move required databases to the Selected databases list of the window and click OK to register databases.

Register Database dialog

Note: This dialog appears only if the Register newly created databases option is enabled in the SQL Script section of Environment Options.

Note: In the Lite version you can register only five databases.

Click the Next button to proceed to the Setting specific options step of the wizard.


Setting specific options

This step of the wizard allows you to set database alias, database options, logs and SSL parameters.

Register Database wizard - Setting specific options - General

Database

Database name

Type in or use the drop-down list to select the database to be registered.

Client encoding

This option allows you to use multibyte encoding method in the database. Use the drop-down list to select the required encoding value, or leave this option to apply the default server encoding.

Auth. method - selecting the authentication method when connecting to the database.

CheckBox Login prompt before connection

Enables SQL Manager for PostgreSQL to prompt for user name and password each time you connect to the database.

CheckBox Refresh objects on connection

This option allows you to enable/disable refreshing objects on connection to the database. It is highly recommended to uncheck this option if your database contains many objects or if connection to the database is slow.

CheckBox Autoconnect at startup

With this option set, connection to the registered database is established automatically at application startup.

CheckBox Show system objects

If this option is checked, PostgreSQL system objects will be displayed in DB Explorer.

CheckBox Ping server every ... seconds

Defines minimal time interval for PostgreSQL server to be pinged. You may find this option useful in some cases.

SSL

Register Database wizard - Setting specific options - SSL

Select the preferable SSL mode: Disabled, Allow, Prefer, Require, Verify CA, Verify Full. Allow, Prefer, Required, or Disabled.

Root certificate

Select the path to the client root.crt file.

Client certificate

Select the path to the client certificate.

Client key

Select the path to the client private key.

Revocation list

Select the file for Certificate Revocation List.

Logs

Register Database wizard - Setting specific options - Logs

CheckBox Enable log of metadata changes

Check this option if you wish to log metadata changes of your database in a file.

Log file

This field is enabled if the Enable log of metadata changes option is selected. Type in or use the Save as btnSaveAs button to specify the path to the *.sql file to store the metadata logs.

CheckBox Enable log of Query Data queries

Check this option if you wish to log your Query Data queries in a file.

Log file

This field is enabled if the Enable log of Query Data queries option is selected. Type in or use the Save as btnSaveAs button to specify the path to the *.sql file to store the logs of SQL queries.

CheckBox Is Unicode

Enable this option to save logs in Unicode. If the option is disabled, ANSI will be used.

Click the Finish button when done to start working with the newly registered database in SQL Manager for PostgreSQL.


Database Registration Info

Use the Database Registration Info dialog to view and edit the registration properties of the database.

To open the dialog, select the database or any of its objects in the DB Explorer tree, then select the Database | btnDBRegistrationInfo Database Registration Info... main menu item, or right-click the database alias in DB Explorer and use the Database Registration Info... context menu item. You can also use the btnDBRegistrationInfo Database Registration Info... button on the main toolbar.

  • Editing connection properties
  • Setting database options
  • Setting display options
  • Setting default directories
  • Setting log options
  • Setting SSL options
  • Setting SSH tunneling options
  • Setting HTTP tunneling options
  • Setting data options
  • Find Option

See also:

Create Database wizard

Register Database wizard

Database Properties


Connection

The Connection section of the Database Registration Info dialog allows you to view and/or edit the connection properties in the corresponding boxes.

Database Registration Info - Editing connection properties

Host name

Stores the name of the Host where the database resides.

Port

Enter PostgreSQL port to connect through.

User name

If necessary, edit the User name used to access the database.

Password

If necessary, edit the Password used to access the database.

Database name

Stores the name of the database.

Database alias

Stores the database alias which is displayed in the DB Explorer tree and SQL Manager tools. By default, a database alias generated by the application has the following format: <database_name> on <host_name>[:<port>]

Host alias

Set the alias for the current host to be displayed in the DB Explorer.

Client encoding

This option allows you to use multibyte encoding method in the database. Use the drop-down list to select the required encoding value, or leave this option to apply the default server encoding.

Auth method

Select the authentication method on connecting to the database.

Once you have specified the connection properties, you can check whether it is possible to establish connection to the database: click the Test Connection button for this purpose. If connection is successful, you will get the 'Connected!' message; otherwise an error message will be returned.

The Load Connection Info... menu allows you to select the alias of a previously registered database and use it for the newly created/configured database.


Options

The Options section of the Database Registration Info dialog allows you to set various options for the database.

Database Registration Info - Setting common database options

Customize common database options according to your needs. The detailed description is given below.

CheckBox Login prompt before connection

Enables SQL Manager for PostgreSQL to prompt for user name and password each time you connect to the database.

CheckBox Show system objects

This option determines whether PostgreSQL system objects are displayed in the DB Explorer tree.

CheckBox Autoconnect at startup

Check this option to specify that SQL Manager for PostgreSQL automatically establishes connection to the registered database at application startup.

CheckBox Refresh objects on connection

This option allows you to enable/disable refreshing objects on connection to the database. It is highly recommended to uncheck this option if your database contains many objects or if connection to the database is slow.

CheckBox Schema-organized database tree

If this option is disabled, the object tree is built without grouping into schemas.

CheckBox Ping server every ... seconds

Defines minimal time interval for PostgreSQL server to be pinged. You may find this option useful in some cases.


Session settings

The Session Settings section of the Database Registration Info dialog allows you to define specific server parameters according to your needs.

Database Registration Info - Session Settings

Right-click an item within the list to call the context menu allowing you to add/edit/remove a parameter and export parameters list to a file of preferable format by means of the Export Data Wizard.

The following dialog appears on adding or editing parameters.

Database Registration Info - Session Settings - Add parameter

This dialog allows you to change the parameter name, set its value, browse parameter info and supply a description, if necessary.

To obtain more information on specific parameters, refer to PostgreSQL documentation.


Display options

The Display Options section of the Database Registration Info dialog allows you to specify which objects will be displayed in the Database Explorer tree.

CheckBox Use custom color for DB editors

With this option checked the text color for editor tabs is black. To apply user font color uncheck the option and select the color.

Database Registration Info - Setting display options

For your convenience the Select All and Deselect All functions are implemented in the context menu of the objects list area.

See also:

Database Objects Management


Directories

The Directories section of the Database Registration Info dialog allows you to set the directories to be used by default for database extract, data export, data import, saving HTML reports, creating reports, saving Local Scripts operations.

Database Registration Info - Setting default directories


Logs

The Logs section of the Database Registration Info dialog allows you to specify log file names for metadata changes logging and SQL query logging, if necessary.

Logging can be useful when you are going to move the changes made in the development database to the production database.

Database Registration Info - Setting log options

Metadata changes

CheckBox Enable log of metadata changes

Check this option if you wish to log metadata changes of your database in a file.

Metadata log file

This field is enabled if the Enable log of metadata changes option is selected. Type in or use the Save as btnSaveAs button to specify the path to the *.sql file to store the metadata logs.

Query data

CheckBox Enable log of Query Data queries

Check this option if you wish to log your queries in a file.

Query Data log file

This field is enabled if the Enable log of Query Data queries option is selected. Type in or use the Save as btnSaveAs button to specify the path to the *.sql file to store the logs of SQL queries: date/time of query execution, SQL text, execution result or errors (if any).

CheckBox In Unicode

Enable this option to save logs in Unicode. If the option is disabled, ANSI will be used.


SSL options

The SSL tab allows you to connect to the server via encrypted channel for increased security.

SSL mode

Select the required SSL mode from the dropdown menu: Disabled, Allow, Prefer, Require, Verify CA, Verify Full.

Database Registration Info - SSL

Root certificate

Select the path to the client root.crt file.

Client certificate

Select the path to the client certificate.

Client key

Select the path to the client private key.

Revocation list

Select the file for Certificate Revocation List.


SSH tunneling options

The SSH Tunneling section of the Database Registration Info dialog allows you to enable/disable SSH tunneling for connection to the database and set all the necessary SSH tunneling parameters.

CheckBox Connect through the Secure Shell (SSH) tunnel

Select this option to establish connection to an intermediate SSH server and forward all PostgreSQL commands through the secure tunnel.

Specify SSH Host name, SSH port, SSH user name, SSH password, the path to the SSH key file (if necessary) in the corresponding boxes.

See SSH connection properties for details.

Note: PostgreSQL host name on the Connection page should be set relatively to the SSH server in this case. For example, if both PostgreSQL and SSH servers are located on the same computer, you should specify localhost as Host name instead of the server's external host name or IP address.

Database Registration Info - Setting SSH tunnel options

Please note that either SSH tunneling, or HTTP tunneling can be used for one connection, but not both types simultaneously.

See also:

HTTP tunneling options


HTTP tunneling options

The HTTP Tunneling section of the Database Registration Info dialog allows you to enable/disable HTTP tunneling for connection to the database and set the necessary HTTP tunneling parameters.

CheckBox Connect through the HTTP tunnel

Select this option to access PostgreSQL server through the HTTP protocol in case of Internet access through HTTP proxy only, or if the server does not allow direct connections to PostgreSQL, but allows HTTP connections.

In order to use HTTP tunneling for the connection, you need to upload the tunneling emsproxy.php script to the webserver and specify the URL in the corresponding box in the following format: http://webserver_address/emsproxy.php

See HTTP connection properties for details.

Note: In case of using this connection method, the response will be slower as compared to the direct connection or SSH Tunneling method, as the data are XML encoded and HTTP is stateless by nature.

Database Registration Info - Setting HTTP tunnel options

Please note that either SSH tunneling, or HTTP tunneling can be used for one connection, but not both types simultaneously.

See also:

SSH tunneling options


Data options

The Data Options section of the Database Registration Info dialog allows you to define options for data view. These options will be applied only to this database. Default settings for newly registered databases can be defined on the Grid | Data Options page of the Environment Options dialog.

Database Registration Info - Setting data options

Default limit options in table and view editors

Define the number of records to be selected on opening the Data tab of Table Editor and View Editor:

RadioButton Select all records from a table

RadioButton Select only ... records (you should set the number of records using the corresponding spinner control)

Advanced

CheckBox Use transactions in object editors, Query Data and Design Query

If this option is enabled, a transaction is active until the 'Data' tab is closed or the 'Commit' button is pressed; all edited records are blocked until the transaction is committed. If this option is disabled, the transaction starts and is immediately committed (autocommit) on saving each record which is blocked only for a short period of time.

CheckBox Asynchronous query execution

Check this option to allow executing queries in background mode (asynchronously).

CheckBox Use separate connections for each data view within a database

Select this option to use a separate connection for each data view within a database. Disabling this option is recommended if maximum allowed number of connections is too low. Note that this option is only available when the Use transactions in Data tab of object editors, Query Data and Design Query option is enabled.

CheckBox OID columns as BLOB

Enable this option if you want the OID column to be displayed as a BLOB (OID - object ID - the object identifier of a row).

Default grid mode

It defines grid mode which will be used by default on Data tab.

RadioButton Load all records

The grid loads all records from a dataset. This option increases the grid performance by reloading only changed dataset records when updating. In this mode all features (automatic sorting, filtering and summary calculations) are available.

RadioButton Load visible records

The grid loads only a fixed number of dataset records into memory. This option minimizes dataset loading time. The automatic sorting, filtering, summary calculations are not supported in this mode.

With the Load all records option enabled, when loading data, all the records are loaded into grid buffers. In this mode opening the tables with many records may take a very long time. But in this case you have some advantages: e.g. in the filter drop-down list the column headers are displayed with the values for quick filter; it is possible to open several sublevels at the same time when viewing data in master-detail view, etc.

Because opening and other operations with an object consisting of many records takes sufficient time the Load visible records mode should be used instead. It can be set individually for each table and is saved between sessions (can be set through the context menu of the grid).

Load visible rows mode if records more than...

Set this option to switch to the Load visible rows mode when the number of records in the dataset exceeds the specified value.

See also:

Data View

Grid options


Change management

The Change Management section of the Database Registration Info dialog allows you to define settings for database version control.

Change management system (Version control system) enables teamwork under a project.

This system can be useful for single developers, whose databases have complex business logic in procedures, triggers etc. Version control system (VCS) provides change management means to control changes of objects.

VCS contains service information about database added to system, about databases included to a branch etc. If the database backup is created on client workstation, then the label backup will be stored in VCS repository. If the backup is created on server, VCS system only remembers its location.

Version control in SQL Manager for PostgreSQL provides:

  • Systematization of release new versions of database process;
  • Storing different database versions;
  • Tracking of database changes ;
  • Getting (storing, testing) change scripts which reveal differences between two database states;
  • Possibility to rollback database to definite state;
  • Control of database changes.

For database administrators:

  • Control of database changes.

CheckBox Enabled

Use this option to enable/disable change management feature for the database. Enabling this option provides access to the VCS settings.

Note: iconDatabase with Change Management Databases with Change Management enabled can have different icon in the DB Explorer tree.

Click the corresponding button to launch the Repository management wizard. It allows you to create/check out repository.

Database Registration Info - Change Management

Version control provider

Source provider

Use the drop-down list to select version control provider.

The following versions of the VCS providers are supported:

  • CVS (version 1.9 or higher)
  • Microsoft Visual SourceSafe (version 8.0)
  • Team Foundation Server (2005, 2008, 2010)

Client program installation is required for each version control system.

Note: .Net Framework 4.0 must be installed for working with 2005/2008 Team Foundation Server.

Specify User Name and Password if VCS repository requires authorization.

The Properties button opens the Provider Settings dialog. Use this dialog to view/edit or test the selected VCS provider settings:

CVS

SVN

VSS

TFS

Location

Version control project

Use this field to define the location of VCS project. Format of the server path depends on the VCS selected.

Working folder

Specify the location of the local repository directory.

Branch name

Displays name of the database branch. The branch containing information about current database is selected automatically. If there is no branch with information about current database in VCS, the Version Control Branches dialog appears. Use this dialog to select the branch to link with the current database.

The Copy From... allows you to get repository settings from any of the registered databases with VCS settings defined.

See also:

Enable change management

Create branch/label/tag

Check repository

Get change script

Release new database version

Changes history


Repository management wizard

This wizard allows you to create VCS repository for the database or checkout the existing one. See the instructions below to get sufficient information to perform the operation.

Repository management wizard - Selecting operation

Selecting operation

Selecting version control provider

Configuring provider settings

Specifying repository settings

Defining label options

Performing operation


Selecting operation

This step of the wizard allows you to select the operation to be performed.

Repository management wizard - Selecting operation

It is possible either to RadioButton Create new repository or RadioButton Checkout an existing one.

Note: If you are using VCS system for the first time select the RadioButton Create new repository mode.

Click the Next button to proceed to the Selecting version control provider step of the wizard.


Selecting version control provider

Use this step to select version control provider:

RadioButton Concurrent Version System,

RadioButton Subversion,

RadioButton Visual SourceSafe,

RadioButton Team Foundation System.

Repository management wizard - Selecting provider

Click the Next button to proceed to the Configuring version control provider step of the wizard.


Configuring provider settings

This step of the wizard contains the set of options necessary to define the version control repository.

Set of options available in this step depends on the provider selection made in the Selecting version control provider step of the wizard:

CVS

SVN/VSS

TFS


CVS

This step of the wizard contains settings available for CVS provider.

Repository management wizard - Configuring provider settings - CSV

Specify Username and Password to authorize to the repository.

CVS executable

Use this field to locate the 'cvs.exe' file. Type the path to the file or use the ExplorerButton Explorer button to locate it within the Open dialog.

CVSROOT

This section allows you to define CVSROOT variable's value - set protocol, repository location, default user name and so on. At least the CVS repository location must be specified. You can RadioButton Use environment variable or specify RadioButton custom value.

To check the defined repository settings click the Test button.

Click the Next button to proceed to the Specifying repository settings step of the wizard.


SVN/VSS

Use this step to define Subversion/Visual SourceSafe version control provider settings.

Repository management wizard - Configuring provider settings - VSS

Specify Username and Password to authorize to the repository.

Locate the SourceSafe database file for the VSS or Subversion client libraries path for the SVN using the corresponded field. You can click the ExplorerButton Explorer button to define file location.

To check the defined repository settings click the Test button.

Click the Next button to proceed to the Specifying repository settings step of the wizard.


TFS

Use this step to define settings for Team foundation server version control provider.

Repository management wizard - Configuring provider settings - TFS

Specify Username and Password to authorize to team foundation server.

Server

Define HTTP-address of the TFS server. For example: 'http://server:8080' or 'http://localhost:8080'.

Workspace

Select the workspace on the TFS server to be used with repository.

Click the Test client button to check TFS client availability.

Click the Test connection button to check connection to the TFS server with the settings defined above.

Click the Next button to proceed to the Specifying repository settings step of the wizard.


Specifying repository settings

Use this step of the wizard to define repository location.

Repository management wizard - Specify repository settings

Server path

Path to the repository on the VCS server. Specify the repository name in this field only when checking out the repository. You need to specify the server path under convention of version control system used. You can specify the repository name in this field only when extracting information from the repository and creating a local copy (check_out operation).

Local path

Location of repository working folder on client computer without repository directory. Directory with the Repository name must be absent form the specified local path folder or empty.

Repository name

Name of the repository to be created. This field is disabled when checking out the repository.

Click the Next button to proceed to the Defining label options step of the wizard.


Defining label options

This step appears only when creating new repository. Use this step to define database label options.

Repository management wizard - Defining label options

Backup storage location

This section defines the directory to store backup copies that are created with the label. By default these copies are stored in the RadioButton Version control repository. To set different location activate the RadioButton Separately option.

CheckBox Backup metadata only

Use this option to define whether to include data in backups created with the label.

Click the Next button to proceed to the final step of the wizard.


Performing operation

This step informs you that all necessary settings are defined and version control repository can be created/checked out.

Repository management wizard - Performing operation

To close the wizard after successful completion of the operation use the respective option.

Click the Run button to perform the operation.


CVS

CVS executable

Use this field to locate the 'cvs.exe' file. Type or use the ExplorerButton Explorer button to locate the file within the standard Open dialog.

Provider settings - CVS

CVSROOT

This section allows you to set CVS repository settings. At least the CVS repository location must be specified. You can RadioButton Use environment variable or specify RadioButton custom value for the purpose.

To check the defined repository settings click the Test button.


SVN

Locate the Subversion client libraries path in the corresponding field. You can click the ExplorerButton Explorer button to define file location using the Open dialog.

Note that SQL Manager supports only 32-bit SVN clients.

Provider settings - Subversion

To check the defined repository settings click the Test button.


VSS

Locate the SourceSafe database file, using corresponded field. You can click the ExplorerButton Explorer button to define file location using the Open dialog.

Provider settings - SourceSafe

To check the defined repository settings click the Test button.


TFS

Server

Define HTTP-address of the TFS server. For example: 'http://server:8080' or 'http://localhost:8080'.

Workspace

Select the workspace on the TFS server to be used when working with the repository.

Provider settings - Team Foundation Server

Click the Test client button to check TFS client availability.

Click the Test connection button to check connection to the TFS server with settings defined above.


Version Control Branches

Using database change management functionality in SQL Manager for PostgreSQL implies that a database is linked with VCS repository branch. Therefore with each repository branch a database copy is created.

When creating new database repository the name of this database is stored in the head/trunk branch of VCS repository. When you are using the existing repository, the working branch is defined automatically by the database name. If no branches of the repository contain information about the database, then you will be offered to associate existing repository branch with the database:

Database Registration Info - Change Management - Question

Press Yes to open the Version Control Branches dialog to select the needed branch:

Database Registration Info - Change Management - Select_branch

Branch selection needs to be confirmed in the appeared window.

Database name in the selected branch will be change with the current database name.

Database Registration Info - Change Management - Replace database of the branch


Find Option

The Find Option section allows you to search for options available within the Database Registration Info dialog easily and quickly.

Option

In this field you can enter the name of the option to search for within the database registration options.

Database Registration Info - Find Option

The Available options area lists all options of the Database Registration category according to the specified name. The Option Kind, Category and Group columns specify option type and location.

Select the required option in the list and click Show Option to open the corresponding section where you can view/edit the value of this option. For your convenience the required option is marked with an animated iconFindOption icon.


Database Properties

The Database Properties dialog allows you to view/edit a number of properties which can be changed to optimize database performance.

To open the dialog, right-click the database alias in DB Explorer and select the Database Properties... context menu item, or use the btnDBProperties Properties button on the DB Explorer toolbar.

A number of database options that determine the characteristics of the database can be set for each database. These options are unique to each database and do not affect other databases.

  • General
  • Description
  • Permissions
  • Find Option

See also:

Create Database wizard

Register Database wizard

Database Registration Info


General

The General section of the Database Properties dialog allows you to view/edit general database properties: Database name, Database owner, OID, Encoding, Default tablespace, Database size (in MB), Connection limit.

Database Properties - General

Database name

Displays the name of the database.

Database owner

Specifies the database user who owns the database (for PostgreSQL 7.3 or higher).

OID

Displays the object identifier of the database.

Encoding

Displays the encoding used in the database.

Default tablespace

Displays the default tablespace for the database (for PostgreSQL 8.0 or higher).

Database size

Displays the size of the database (in megabytes).

Connection limit

Specifies the time limit for connecting to the database (for PostgreSQL 8.1 or higher).

CheckBox No limit

Enable the option for unlimited connections.

See also:

Description

Permissions

Find Option


Description

The Description section of the Database Properties dialog allows you to add/edit an optional description for the database.

Database Properties - Description

See also:

General

Permissions

Find Option


Permissions

The Permissions section of the Database Properties dialog allows you to view and set grants for the current database.

Right-click on the grid cell where the row stands for a group or user, and the column is the operation for granting (OWN, CRT, etc), then select the Grant item from the context menu to permit the selected operation to the group/user. See Managing privileges for details.

OWN (OWNER)

Allows to set the new owner of the database (to alter the owner, you must own the database and also be a direct or indirect member of the new owning role).

CONN (CONNECT)

Allows the user to connect to the current database (note that this column appears only when working with server version 8.2 or higher).

CRT (CREATE)

Allows new schemas to be created within the database.

TMP (TEMPORARY)

Allows temporary tables to be created while using the database.

Database Properties - Permissions

See also:

General

Description

Find Option


Find Option

The Find Option section allows you to search for options available within the Database Properties dialog easily and quickly.

Option

In this field you can enter the name of the option to search for within the database properties.

Database Properties - Find Option

The Available options area lists all options of the Database Properties category according to the specified name. The Option Kind, Category and Group columns specify option type and location.

Select the required option in the list and click Show Option to open the corresponding section where you can view/edit the value of this option. For your convenience the required option is marked with an animated iconFindOption icon.

See also:

General

Description

Permissions


Database Registration Manager

Database Registration Manager allows you to register new databases and delete the registration of non-existing databases.

To open Database Registration Manager use the corresponding item of the database context menu.

Database Registration Info - Database Registration Manager

Table contains all databases located on the selected host. You can change Host selection using the appropriate drop-down list in the navigation bar.

Check all databases to be registered.

For automatic registration of selected databases click the iconCommit Apply changes button.

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Register Database wizard


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Database Registration Manager.

Database Registration Manager - Using Navigation bar

The Navigation bar of Database Registration Manager allows you to:

Host

iconHost select a host

General

iconRefresh Refresh the list of databases

iconCommit Apply changes - register selected databases

Select databases located on the host, but not registered in <PRODUCT_TITLE>

Delete registration of the database removed from the server.

Legend

iconDB Exist on host

Removed from host

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Database Objects Management

SQL Manager for PostgreSQL provides powerful tools to manage database objects.

To obtain detailed information concerning PostgreSQL database objects, refer to the official PostgreSQL server documentation.

Note: Before working with database objects in SQL Manager for PostgreSQL you should connect to the database first.

Creating Database Objects

To create a database object:

  • select the Database | New Object... main menu item;
  • select the type of object within the New Object dialog;
  • follow the steps of the wizard which guides you through the entire process of creating the object, or set the object properties using its editor - depending on the selected object type.

Note that you can also create a database object by selecting the appropriate context menu item of the DB Explorer tree or using the Ctrl+N shortcut.

To create a new object with the same properties as one of existing objects has:

  • select the Database | Duplicate Object... main menu item;
  • follow the instructions of Duplicate Object Wizard.

Alternatively, you can right-click an object in the DB Explorer tree and select the Duplicate Object <object_name>... context menu item.

Editing Database Objects

To edit a database object:

  • select the database object in the DB Explorer tree;
  • right-click the object to call its context menu and select the Edit <object type> <object name> context menu item, or double-click the object to open it in its editor;

Renaming Database Objects

To rename a database object:

  • select the object to rename in the DB Explorer tree;
  • right-click the object and select the Rename <object type> <object name>... item from the context menu;
  • edit the object name using the Rename Object... dialog.

Note: This operation is possible for all objects except for schemas, domains, rules, base types, composite types, enumerated types, operators, tablespaces.

Dropping Database Objects

To drop a database object:

  • select the database object in the DB Explorer tree;
  • right-click the object to call its context menu and select the Drop <object type> <object name> context menu item;
  • confirm dropping in the dialog window.

Note: If more convenient, you can also use the following shortcuts:

Ctrl+N to create a new object;

Ctrl+O to edit the selected object;

Ctrl+R to rename the object;

Shift+Del to drop the object from the database.

When using an object editor, you can benefit from tabs. To switch between tab views, click on their respective tabs at the top of the main editor window. You can do it at any time, since the tab views are absolutely independent.

To compile a newly created or edited object, you can use the iconCompile Compile item available within the Navigation bar or Toolbar of the object editor.

See also:

Getting Started

Database Explorer

Database Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Database Tools

Services

Options

How To...


New Object

The Create New Object dialog allows you to select the type of the object to be created and run the appropriate wizard or editor.

To open the dialog, select the Database | iconNewObject New Object... main menu item.

Use the Database drop-down list to select the alias of the database where the new object should be created. Pick an object type icon and click OK to invoke the corresponding wizard or dialog.

Database Objects management - Create New Object

See also:

Operations with database objects

Duplicate Object Wizard

Schemas

Schema Objects

Non-schema Objects


Duplicate Object Wizard

Use the Duplicate Object Wizard to create a new database object of the same type and having the same properties as one of the existing ones.

To run the wizard, select the Database | iconDuplicateObject Duplicate Object... main menu item, or right-click an object of the desired type in the DB Explorer tree and use the Duplicate <object type> <object name>... context menu item.

  • Selecting the source database
  • Selecting object to duplicate
  • Selecting destination database
  • Modifying the new object's definition

See also:

Operations with database objects

New Object

Schemas

Schema Objects

Non-schema Objects


Selecting the source database

This step of the wizard allows you to select the source database containing the source object to be duplicated.

Duplicate Object Wizard - Selecting the source database

Click the Next button to proceed to the Selecting object to duplicate step of the wizard.


Selecting object to duplicate

Use the Objects drop-down menu to select the type of object you intend to duplicate.

Select a database object to copy its properties to the new object.

Hint: The context menu of the objects list area allows you to specify whether objects of the specified type should be displayed as icons or as list.

Duplicate Object Wizard - Selecting object to duplicate

Click the Next button to proceed to the Selecting destination database step of the wizard.


Selecting destination database

Select the target database and schema (New object namespace) to create the new object in, set the name of the new database object.

Check the CheckBox Copy data option to copy data from the source table to the new one.

Duplicate Object Wizard - Selecting destination database

Click the Next button to proceed to the Modifying the new object's definition step of the wizard.


Modifying the new object's definition

This step of the wizard allows you to browse the result SQL statement.

If necessary, you can edit the definition of the new object.

Duplicate Object Wizard - Modifying the new object's definition

CheckBox Close the wizard after duplicating

If this option is selected, the wizard is closed automatically when the new object is created.

CheckBox Open object when finished

Select this option to open the newly created object in its editor.

Click the Run button to create the object.


Schemas

A Schema is essentially a namespace: it can be defined as a collection of database objects that form a single namespace. A namespace is a set in which each element has a unique name.

Creating Schemas

  • select the Database | New Object... main menu item;
  • select Schema in the Create New Object dialog;
  • define schema properties using the appropriate tabs of Schema Editor.

Hint: To create a new schema, you can also right-click the Schemas node or any object within this node in the DB Explorer tree and select the New Schema item from the context menu.

To create a new schema with the same properties as one of existing schemas has:

  • select the Database | Duplicate Object... main menu item;
  • follow the instructions of Duplicate Object Wizard.

Alternatively, you can right-click a schema in the DB Explorer tree and select the Duplicate Schema <schema_name>... context menu item.

Duplicate Object Wizard allows you to select the database to create a new schema in, and to edit the result SQL statement for creating the schema.

Editing Schemas

  • select the schema for editing in the DB Explorer tree (type the first letters of the schema name for quick search);
  • right-click the object and select the Edit Schema <schema_name>... context menu item, or simply double-click the schema;
  • edit schema properties using the appropriate tabs of Schema Editor.

Dropping Schemas

  • select the schema to drop in the DB Explorer tree;
  • right-click the object and select the Drop Schema <schema_name>... context menu item;
  • confirm dropping in the dialog window.

Note: If more convenient, you can also use the following shortcuts:

Ctrl+N to create a new schema;

Ctrl+O to edit the selected schema;

Shift+Del to drop the object from the database.

See also:

Operations with database objects

New Object dialog

Duplicate Object Wizard

Schema Objects

Non-schema Objects


Schema Editor

Schema Editor allows you to manage PostgreSQL schemas efficiently. It opens automatically when you create a new schema and is available on editing an existing one (see Create schema and Edit schema for details).

To open a schema in Schema Editor, double-click it in the DB Explorer tree.

  • Using Navigation bar and Toolbar
  • Creating/editing schema
  • Browsing object dependencies
  • Editing schema description
  • Viewing DDL definition


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Schema Editor.

Schema Editor - Using Navigation bar

Object

iconDB select a database

select a schema for editing

General

iconCompile compile the schema (if it is being created/modified)

iconSaveDescription save the schema description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the schema

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the schema:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing schema

Use the Schema tab of Schema Editor to create/edit a schema and specify its properties.

Schema Editor - Editing schema definition

Name

Specify the name by which the schema is identified within the database.

Owner

Specify the name of the database-level principal (user or role) that will own the schema. This principal may own other schemas, and may not use the current schema as its default schema.


Schema Objects

A schema is a collection of logical structures of data, or schema objects. A schema is owned by a database user. Each user can own a single schema. Schema objects can be created and manipulated with SQL and include the following types of objects:

  • Tables
  • Views
  • Functions
  • Procedures
  • Domains
  • Rules
  • Sequences
  • Base Types
  • Composite Types
  • ENUM Types
  • Range Types
  • Aggregates
  • Operators
  • Collations
  • Statistics

Use the DB Explorer tree to navigate within the existing schemas and their objects.

See also:

Operations with database objects

New Object dialog

Duplicate Object Wizard

Schemas

Non-schema Objects


Tables

Relational databases store all their data in Tables. A table is a data structure consisting of an unordered set of horizontal rows, each containing the same number of vertical columns. The intersection of an individual row and column is a field that contains a specific piece of information. Much of the power of relational databases comes from defining the relations among the tables.

Creating Tables

  • select the Database | New Object... main menu item;
  • select Table in the Create New Object dialog;
  • define table properties and fields using the appropriate tabs of Table Editor.

Hint: To create a new table, you can also right-click the Tables node or any object within this node in the DB Explorer tree and select the New Table... item from the context menu.

To create a new table with the same properties as one of existing tables has:

  • select the Database | Duplicate Object... menu item;
  • follow the instructions of Duplicate Object Wizard.

Alternatively, you can right-click a table in the DB Explorer tree and select the Duplicate Table <table_name>... context menu item.

Duplicate Object Wizard allows you to select the database to create a new table in, and to edit the result SQL statement for creating the table.

Editing Tables

To edit an existing table (manage its columns, indexes, data, etc.):

  • select the table for editing in the DB Explorer tree (type the first letters of the table name for quick search);
  • right-click the object and select the Edit Table <table_name> context menu item, or simply double-click the table;
  • edit table subobjects and data using the appropriate tabs of Table Editor.

To change the name of a table:

  • select the table to rename in the DB Explorer tree;
  • right-click the table alias and select the Rename Table <table_name>... item from the context menu;
  • edit the table name using the Rename Object... dialog.

Dropping Tables

  • select the table to drop in the DB Explorer tree;
  • right-click the object and select the Drop Table <table_name>... context menu item;
  • confirm dropping in the dialog window.

Note: If more convenient, you can also use the following shortcuts:

Ctrl+N to create a new table;

Ctrl+O to edit the selected table;

Ctrl+R to rename the table;

Shift+Del to drop the object from the database.


New table

The New Table window is a mode of Table Editor that opens automatically when you create a new table (see Create table for details) and allows you to create a new table, set table properties, specify table columns and edit table description.

To call Table Editor for creating a new table, you can right-click the Tables node or any object within this node in the DB Explorer tree and use the Ctrl+N shortcut.

  • Using Navigation bar and Toolbar
  • Setting table properties
  • Specifying table columns


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Table Editor.

New table - Using Navigation bar

Database

iconDB select a database to create a new table in

General

iconCompile compile the newly created table

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the table:

Columns

add a new column

edit selected column

drop selected column(s)

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Setting table properties

Use the Table tab of Table Editor to create a table and specify its properties.

Table name

Select a schema and enter a name for the new table. Note that table names must comply with the rules for identifiers and must be unique within the schema. A table name can contain a maximum of 128 characters.

Table type

RadioButton Ordinary table

Use this option to create an ordinary PosgreSQL table.

RadioButton Foreign table

Select this option to create a foreign table. Such tables allow data stored outside the database to be used like native PostgreSQL-stored data. From the drop-down list select the foreign server to be used for the foreign table.

If the selected foreign server has the 'postgres_fdw' as a data wrapper then the Select Table button becomes available.

RadioButton Temporary table

Select this option to create a temporary table. A temporary table will automatically be deleted if the connection dies and the name is valid per connection. This means that two different connections can both use the same temporary table name without conflicting with each other or with an existing table of the same name (the existing table is hidden until the temporary table is deleted).

Behavior on end of transaction

This group allows you to define the temporary table behavior at the end of a transaction block:

RadioButton Preserve rows

RadioButton Delete rows

RadioButton Drop table

New table - Setting table properties

Table owner

Use the drop-down list to select the user that will own the table being created.

Tablespace

Use the drop-down list to specify the new table data storage (a tablespace).

Options

CheckBox With OIDs

This option specifies whether rows of the new table should have OIDs (object identifiers) assigned to them.

CheckBox Unlogged

For PostgreSQL ver. 9.1 and above.

If specified, the table is created as an unlogged table. Data written to unlogged tables is not written to the write-ahead log, which makes them considerably faster than ordinary tables.

Note: An unlogged table is automatically truncated after a crash or unclean shutdown.

Fillfactor

The fillfactor for a table is a percentage between 10 and 100. 100 (complete packing) is the default. When a smaller fillfactor is specified, INSERT operations pack table pages only to the indicated percentage; the remaining space on each page is reserved for updating rows on that page. This gives UPDATE a chance to place the updated copy of a row on the same page as the original, which is more efficient than placing it on a different page. For a table whose entries are never updated, complete packing is the best choice, but in heavily updated tables smaller fillfactors are appropriate.

CheckBox Use default fillfactor.

Check this option to set fillfactor value to 100.

Fillfactor

Specify the custom fillfactor value in this field.

Note: To set this value you need to uncheck CheckBox Use default fillfactor option.

Partition

Partition by

Select the column to set a partition key.

For values

Set the range of partition table values.

Inherits from

This area allows you to define the table(s) to inherit properties from. Use of inheritance creates a persistent relationship between the new child table and its parent table(s). Schema modifications to the parent(s) normally propagate to children as well, and by default the data of the child table is included in scans of the parent(s).

To select a table, you need to move it from the Available Tables list to the Selected Tables list. Use the Move to Selected Move to Available buttons or drag-and-drop operations to move the tables from one list to another.

The following icons distinguish inherited tables in Database Explorer:

iconHasInheritedTable - means that there is a table inherited from this table

iconIsInherited - means that the table is inherited from another one

iconIsInheritedandHasInherited - means that the table is inherited from a table and there is another table inherited from this table

To compile the table, use the iconCompile Compile item available within the Navigation bar.


Specifying columns

The Columns tab is intended for setting up table columns. Double-click a column to open Column Editor for editing the column.

Right-click within the Table Columns area to display the context menu allowing you to add, insert, edit or delete columns.

Columns management tools are also available through the Navigation bar and toolbar of Table Editor.

New table - Specifying fields

The Columns list provides the following attributes of each column of the new table:

Primary Key

Column Name

Data Type

Size

Precision

Array Dims

Not Null

Unique

Default Value

Comment

For details see columns.

To compile the table, use the iconCompile Compile item available within the Navigation bar or toolbar.


Foreign table options

Use this tab to define options to be associated with the new foreign table or one of its columns. This tab is available for editing if the RadioButton Foreign table is selected on the Table tab.

Table Editor - Foreign table options

To add and delete options use the New Option and Delete Option(s) context menu items.

The allowed option names and values are specific to each foreign data wrapper and are validated using the foreign-data wrapper's validator function. Duplicate option names are not allowed (although it's OK for a table option and a column option to have the same name).


Table Editor

Table Editor is the basic SQL Manager tool for working with tables. It opens automatically in the New table mode when you create a new table and is available on editing an existing one (see Create table and Edit table for details).

Table Editor allows you to create, edit and drop table's columns, indexes, foreign keys and other table subobjects, manage table data, properties and much more.

To open a table in Table Editor, double-click it in the DB Explorer tree.

  • Using Navigation bar and Toolbar
  • Managing table columns
  • Changing columns order
  • Managing table foreign keys
  • Managing table checks
  • Managing table indexes
  • Managing table triggers
  • Managing rules
  • Managing policies
  • Browsing object dependencies
  • Working with table data
  • Editing table description
  • Viewing DDL definition
  • Setting object permissions
  • Table properties


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Table Editor.

Table Editor - Using Navigation bar

Object

iconDB select a database

select a table for editing

General

iconSaveDescription save the table description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the table

iconOptions adjust Table Editor options

iconRestoreDefaultSize restore the default size and position of the editor window

Tools

analyze and vacuum the table

cluster the table indexes

truncate data of the table

reindex the table indexes

create a view based on the table

view the dependency tree for the table

Explorer

iconDBExplorer browse the table subobjects using the Explorer tree

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the table:

Columns

add a new column

edit selected column

drop selected column(s)

Foreign keys

add a new foreign key

edit selected foreign key

drop selected foreign key(s)

Checks

add a new check

edit selected check

drop selected check(s)

Indices

add a new index

edit selected index

drop selected index(-es)

Triggers

add a new trigger

edit selected trigger

drop selected trigger(s)

Rules

add a new rule

edit selected rule

drop selected rule(s)

Policies

Table Editor - Policies New add a new policy

Table Editor - Policies Edit edit selected policy

Table Editor - Policies Drop drop selected policy(s)

Data Management

iconCommit commit transaction

iconRollback rollback transaction

Note: These actions are available if the CheckBox Use transactions in object editors, Query Data and Design Query option is checked in the Database Registration Info | Data options dialog.

export data from the table using Export Data Wizard

export data from the table as SQL script using Export as SQL Script Wizard

import data into the table using Import Data Wizard

save data

load data

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Managing columns

The Columns tab is intended for managing table columns.

Hint: This tab is selected by default upon opening Table Editor if the Always open the first tab option is enabled on the Tools | Object Editors page of the Environment Options dialog.

Double-click a column to open Column Editor for editing the column.

Right-click a column to display the context menu allowing you to create new, edit, drop, rename, duplicate the selected column, or reorder columns of the table. Using the menu you can also copy to clipboard or export the list of the table columns to any of supported formats.

Columns management tools are also available through the Navigation bar and toolbar of Table Editor.

Table Editor - Managing fields

The Columns list provides the following attributes of each column of the table:

Column Name

Column Type

Key

Not Null

Default

Description

For details see Columns.

If necessary, you can also use the Column Description area to supply a description for each column.


Changing columns order

The Reorder Columns dialog allows you to change the columns order in the table.

To open this dialog, open the table in Table Editor, proceed to the Columns tab there, right-click within the Columns list and select the Reorder Columns item from the context menu.

NB: Since PostgreSQL server does not have a native command for reordering table columns, this operation is implemented in SQL Manager for PostgreSQL by generating the script according to which the data of the original table are copied into a temporary table, then the original table is dropped, and a new table with the same name but having the newly specified order of columns is created, and afterwards all the data are copied from the temporary table into the new one.

Nevertheless such script cannot be executed in some cases. If a table is referenced by another table (e.g. there is a Foreign Key constraint) or is a base table for a view, the Reorder Columns operation cannot be performed. It is recommended to drop Foreign Keys before column reordering, and create them again after the reordering operation is completed.

By default, before the Reorder Columns dialog is opened, a warning window is displayed. Use the Operations by recreating drop-down list to specify whether the Reorder Columns operation will be available after the current operation is performed:

Enabled - such operation will be performed without warnings;

Enabled, show warning - the warning window will appear if the operation requires table recreation;

Disabled - denies operations of this type.

Note: You can change this value any time using the Table altering operations performed via recreation drop-down list available on the Confirmations page of the Environment Options dialog.

Table Editor - Changing fields order - Warning

The columns are displayed in the Column name list in the current order.

To change the columns order, use the [image] [image] buttons or drag-and-drop operations within the list. Click the OK button to view the modification script in the Changing Metadata window and apply changes.

Table Editor - Changing fields order


Managing foreign keys

The Foreign Keys tab is provided for managing table foreign keys. Double-click a foreign key to open Foreign Key Editor for editing the foreign key.

Right-click a foreign key to display the context menu allowing you to create new, edit, drop a foreign key. Using the menu you can also export the list of the table foreign keys to any of supported formats.

Foreign keys management tools are also available through the Navigation bar and toolbar of Table Editor.

Table Editor - Managing foreign keys

The Foreign Keys list provides the following attributes of each foreign key of the table:

Foreign Key Name

On Column

FK Table

FK Column

On Update

On Delete

Deferrable

Check Time

Description

For details see Foreign Keys.

If necessary, you can also use the Foreign Key Description area to supply a description for each foreign key.


Managing checks

The Checks tab is provided for managing table check constraints. Double-click a check to open Check Editor for editing the check.

Right-click a check to display the context menu allowing you to create new, edit, drop the selected check. Using the menu you can also export the list of the table checks to any of supported formats.

Check constraints management tools are also available through the Navigation bar and toolbar of Table Editor.

Table Editor - Managing checks

The Checks list provides the following attributes of each check constraint of the table:

Check Name

Definition

Description

For details see Checks.

If necessary, you can also use the Check Description area to supply a description for each check constraint.


Managing indexes

The Indices tab is provided for managing table indexes. Double-click an index to open Index Editor for editing the index.

Right-click an index to display the context menu allowing you to create new, edit, drop, reindex the selected index, or reindex all indexes. Using the menu you can also export the list of the table indexes to any of supported formats.

Indexes management tools are also available through the Navigation bar and toolbar of Table Editor.

Table Editor - Managing indexes

The Indexes list provides the following attributes of each index of the table:

Index Name

Function

On Column(s)

Type

Unique

Primary Key

Where

Description

For details see Indexes.

If necessary, you can also use the Index Description area to supply a description for each index.


Managing triggers

The Triggers tab is provided for managing table triggers. Double-click a trigger to open Trigger Editor for editing the trigger.

Right-click the area to display the context menu allowing you to create new, edit, drop, enable/disable the selected trigger, or enable/disable all triggers. Using the menu you can also export the list of the table triggers to any of supported formats.

Triggers management tools are also available through the Navigation bar and toolbar of Table Editor.

Table Editor - Managing triggers

The Triggers list provides the following attributes of each trigger of the table:

Trigger Name

Moment

Event

Function

Disabled

Arguments

For details see Triggers.

If necessary, you can also use the Trigger Description area to supply a description for each trigger.


Managing rules

The Rules tab is provided for managing table rules. Double-click a rule to open Rule Editor for editing the rule.

Right-click the area to display the context menu allowing you to create new, edit, drop the selected rule. Using the menu you can also export the list of the table rules to any of supported formats.

Rules management tools are also available through the Navigation bar and toolbar of Table Editor.

Table Editor - Managing rules

The Rules list provides the following attributes of each rule of the table:

Rule Name

Event

Instead

WHERE Condition

Description

See Rules for details.

If necessary, you can also use the Rule Description area to supply a description for each rule.


Table properties

The Properties tab allows you to view/edit common properties of the table: Table name, Schema name, Table options (Storage attributes, Table lock usage, etc.), Table information.

Hint: These properties are also available within a modal dialog which is called through the Table Properties... context menu item of the table alias in DB Explorer.

Table Editor - Table properties

Table name

Select a schema and edit the name of the table. Note that table names must comply with the rules for identifiers. The name of the table must be unique within the schema. A table name can contain a maximum of 128 characters.

Table owner

Use the drop-down list to select the user that will own the table being created.

Tablespace

Use the drop-down list to specify the new table data storage (a tablespace). Check the Move indices too option if you prefer the table indices stored in the specified tablespace.

Options

This group allows you to specify the CheckBox With OIDs, and CheckBox Temporary options.

CheckBox With OIDs

This option specifies whether rows of the new table should have OIDs (object identifiers) assigned to them.

CheckBox Unlogged

For PostgreSQL ver. 9.1 and above.

If specified, the table is created as an unlogged table. Data written to unlogged tables is not written to the write-ahead log, which makes them considerably faster than ordinary tables.

Note: An unlogged table is automatically truncated after a crash or unclean shutdown.

CheckBox Temporary

Check this option to create a temporary table. A temporary table will automatically be deleted if the connection dies and the name is valid per connection. This means that two different connections can both use the same temporary table name without conflicting with each other or with an existing table of the same name (the existing table is hidden until the temporary table is deleted).

Inherits from

This area allows you to define the table(s) to inherit properties from. Use of inheritance creates a persistent relationship between the new child table and its parent table(s). Schema modifications to the parent(s) normally propagate to children as well, and by default the data of the child table is included in scans of the parent(s).

To select a table, you need to move it from the Available Tables list to the Selected Tables list. Use the Move to Selected Move to Available buttons or drag-and-drop operations to move the tables from one list to another.


Managing policies

The Policies tab is provided for managing table policies.

CheckBox Enable row level security

Enables row security on a table. включить

CheckBox Force row level security

Enables row level security for table owner.

Right-click the area to display the context menu allowing you to create new, edit, rename or drop the selected policy. Using the menu you can also export the list of the table policies to any of supported formats. Double-click a policy to open editor for editing the policy.

Policy management tools are also available through the Navigation bar and toolbar of Table Editor.

Table Editor - Policy tab1

See the Policy editor to edit policy properties.


Working with table data

The Data tab displays the table data as a grid by default (see Data View for details). The context menu of this tab allows you to Export Data, Import Data, Export as SQL Script, Save Data, Load Data.

Data management tools are also available through the Navigation bar and toolbar of Table Editor.

While working with data, you are provided with a number of filtering and grouping facilities.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Table Editor - Working with table data

See also:

Working with view data

Data View


Table Services

SQL Manager for PostgreSQL provides a number of powerful tools that allow you to perform various operations over your tables.

The following table services are available in SQL Manager for PostgreSQL:

Analyze & Vacuum Table

Collects statistics about the contents of tables in the database.

Cluster Table

Allows you to cluster a table on its indexes (with PostgreSQL routines used).

Truncate Table

Allows you to truncate a table, i.e. delete all records from the table.

Reindex Table

Allows you to rebuild corrupted indexes.


Analyze & Vacuum Table

Analyze & Vacuum Table Wizard collects statistics about the table contents, and reclaims storage occupied by deleted tuples (optionally). These operations can also be performed for multiple tables with the help of Analyze Tables and Vacuum Tables wizards.

To run the wizard, use the Analyze & vacuum item of the Navigation bar (or toolbar) in Table Editor, or right-click the table alias in the DB Explorer tree and select the Tasks | Analyze & Vacuum Table... item from the context menu.

  • Setting analyze parameters
  • Selecting columns to analyze
  • Running analyze & vacuum service
  • Using templates

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Cluster Table

Truncate Table

Reindex Table


Setting analyze parameters

This step of the wizard allows you to specify basic analyze parameters to be applied to the operation.

Analyze & Vacuum Table - Setting analyze parameters

CheckBox Reclaim storage occupied by deleted tuples

In normal PostgreSQL operation, tuples that are deleted or obsolete due to an update are not physically removed from their table and therefore remain present. Select this option to perform the VACUUM operation that reclaims storage occupied by deleted and obsolete tuples.

CheckBox Compact unused space

This option specifies "full" vacuum which may reclaim more space, but takes much longer and exclusively locks the table (FULL).

CheckBox Freeze tuples

This option enforces "freezing" of tuples (FREEZE). The option is recommended for read-only databases.

CheckBox Show detailed operation report

Check this option to receive a detailed vacuum activity report for the table (VERBOSE).

Click the Next button to proceed to the Selecting columns to analyze step of the wizard.


Selecting columns to analyze

Use this step of the wizard to select the columns to be analyzed using PostgreSQL routines.

To select a column, you need to move it from the Available list to the Selected list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the columns from one list to another.

Analyze & Vacuum Table - Selecting columns to analyze

When you are done, click the Next button to proceed to the Running service step of the wizard.


Running service

This step of the wizard is intended to inform you that all necessary options have been set, and you can start the analyze and vacuum table process.

The Operations tab allows you to view the log of operations and errors (if any).

Analyze & Vacuum Table - Running service

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed.

If necessary, you can save a template for future use.

Click the Run button to complete the operation.


Cluster Table

Cluster Table Wizard allows you to cluster a table on its indexes (with PostgreSQL routines used).

To run the wizard, use the Cluster table item of the Navigation bar (or toolbar) in Table Editor, or right-click the table alias in the DB Explorer tree and select the Tasks | Cluster Table... item from the context menu.

  • Selecting index for clustering
  • Running service
  • Using templates

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Analyze & Vacuum Table

Truncate Table

Reindex Table


Selecting index for clustering

The first step informs you about the operations that will be performed by the wizard.

Cluster Table - Welcome

Click the Next button to proceed to the Selecting index for clustering step of the wizard.

The Selecting index for clustering step lists table indexes. If the table was clustered previously, the index used for that clustering operation is selected by default.

Cluster Table - Selecting index for clustering

Select one index to cluster the table on.

CheckBox Analyze table

Select this option if you want to perform the Analyze table operation as well.

Click the Next button to proceed to the Running service step of the wizard.


Running service

This step of the wizard is intended to inform you that all necessary options have been set, and you can start the cluster table process.

The Operations tab allows you to view the log of operations and errors (if any).

Cluster Table - Run

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed.

If necessary, you can save a template for future use.

Click the Run button to complete the operation.


Truncate Table

The Truncate Table service allows you to truncate a table, i.e. delete all records from the table.

To run the service, use the Truncate table item of the Navigation bar (or toolbar) in Table Editor, or right-click the table alias in the DB Explorer tree and select the Tasks | Truncate Table item from the context menu.

  • Running service

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Analyze & Vacuum Table

Cluster Table

Reindex Table


Running service

By default, before the TRUNCATE operation is performed, a confirmation window is displayed. Click Yes to confirm truncating all data of the table, or No to cancel the operation.

Truncate Table - Question


Reindex Table

The Reindex Table service allows you to rebuild corrupted indexes for a table. This operation can also be performed for multiple tables with the help of Object Reindex wizard.

To run the service, use the Reindex table item of the Navigation bar (or toolbar) in Table Editor, or right-click the table alias in the DB Explorer tree and select the Tasks | Reindex Table... item from the context menu.

  • Running service

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Analyze & Vacuum Table

Cluster Table

Truncate Table


Running service

The service is implemented by issuing the REINDEX TABLE statement. Click Commit to execute the statement. For more information refer to the Changing Metadata window page.

Reindex Table - Running service


Columns

Table fields are managed within the Fields tab of Table Editor.

Creating Columns

  • open the table in Table Editor;
  • proceed to the Columns tab there;
  • right-click the tab area and select the New Columns context menu item, or press the Ins key;
  • define the field properties using the Column Editor dialog.

Editing Columns

  • open the table in Table Editor;
  • proceed to the Columns tab there;
  • right-click the column and select the Edit Column <column_name> context menu item, or simply double-click the column;
  • edit the column properties using the Column Editor dialog.

To change the order of table columns:

  • open the table in Table Editor;
  • proceed to the Columns tab there;
  • right-click a column and select the Reorder Columns <column_name> context menu item;
  • edit columns' order using the Reorder Columns dialog.

Dropping Columns

  • open the table in Table Editor;
  • proceed to the Columns tab there;
  • right-click the field and select the Drop Column <column_name> context menu item;
  • confirm dropping in the dialog window.


Columns Editor

Column Editor allows you to specify column definition and set field properties. It opens automatically when you create a new column and is available on editing an existing one (see Create column and Edit column for details).

To open a column in Column Editor, double-click it in the DB Explorer tree, or use the Edit Column... item of the context menu within the Columns tab of Table Editor.


Editing column definition

Column name

Enter a name for the new column, or modify the name of the column being edited. Note that the name of a column must be unique among all the column names in the table.

Field Editor - Editing field definition

Data type

Type

Here you can set the column type by selecting it from the drop-down list of the standard PostgreSQL data types.

Change by expression

Specify an expression that defines the value of the computed column.

Size

Specify the size value (for certain types). Check the CheckBox Unlimited option to use the maximum values set by PostgreSQL.

Precision

Specify precision for numeric data type column.

Set the number of array dimensions in the Number of array dimensions spinner control. This control is disabled if the column is not an array column.

Collation

Select column collation from the list.

Generated

Select the value for identity column. If ALWAYS is specified, a user-specified value is only accepted if the INSERT statement specifies OVERRIDING SYSTEM VALUE. If BY DEFAULT is specified, then the user-specified value takes precedence.

Storage

You can change the storage type to PLAIN, EXTENDED, EXTERNAL or MAIN.

Compression

Select the compression method: pglz, lz4 or default to be selected by the server. Compression is supported only for variable-width data types, and is used only when the column's storage mode is main or extended.

Column flags

CheckBox Not Null

Check this option to specify that the values for the column should never contain a null value.

CheckBox Primary key

Check this option to include the column into the primary key. Note that if you include a column to a primary key, you should also make it Not Null.

A table typically has a column or combination of columns that contain values that uniquely identify each row in the table. This column, or columns, is called the primary key (PK) of the table and enforces integrity of the table.

CheckBox Unique

Check this option to create a unique key on the column that provides entity integrity for a particular column or columns using a unique index.

The Statistics group enables collection of row-level statistics on database activity.

Number of statistic details

Allows setting the level of row-level statistics on database activity accumulation.

Use the Default Value and the Description tabs of Column Editor to set values taken by default and optional text as a description for the column.


Foreign Keys

A Foreign key constraint (also called a referential integrity constraint) designates a column as the Foreign key and establishes a relationship between that foreign key and a specified Primary or Unique key called the referenced key. A composite Foreign key designates a combination of columns as the foreign key.

Table Foreign keys are managed within the Foreign Keys tab of Table Editor.

Creating Foreign Keys

  • open the table in Table Editor;
  • proceed to the Foreign Keys tab there;
  • right-click the tab area and select the New Foreign Key context menu item, or press the Ins key;
  • define the Foreign key properties using the Foreign Key Editor dialog.

Editing Foreign Keys

  • open the table in Table Editor;
  • proceed to the Foreign Keys tab there;
  • right-click the Foreign key to edit and select the Edit Foreign Key <foreign_key_name> context menu item, or simply double-click the Foreign key;
  • edit the Foreign key properties using the Foreign Key Editor dialog.

Dropping Foreign Keys

  • open the table in Table Editor;
  • proceed to the Foreign Keys tab there;
  • right-click the Foreign key and select the Drop Foreign Key <foreign_key_name> context menu item;
  • confirm dropping in the dialog window.


Foreign Key Editor

Foreign Key Editor allows you to specify foreign key definition and set foreign key properties. It opens when you create a new foreign key or edit an existing one (see Create Foreign Key and Edit Foreign Key for details).

To open a foreign key in Foreign Key Editor, double-click it in the DB Explorer tree, or use the Edit Foreign Key... item of the context menu within the Foreign Keys tab of Table Editor.

  • Editing foreign key definition
  • Editing foreign key description


Editing foreign key definition

Use the Foreign Key tab of Foreign Key Editor to create/edit a foreign key constraint and specify its properties.

Foreign key name

Enter a name for the new foreign key, or modify the name of the foreign key being edited.

CheckBox Not validated (for Postgres 9.1 and higher)

If this option is selected then a foreign key can initially be added to a large existing table without checking its initial contents, but new tuples must comply with it.

Foreign table

The drop-down list of tables allows you to select the table for which the foreign key is created.

Foreign Key Editor - Editing foreign key definition

The Table Columns area allows you to select Foreign key column(s).

To select a column, you need to move it from the Available Columns list to the Included Columns list. Use the Move to Selected Move to Available buttons or drag-and-drop operations to move the columns from one list to another.

Foreign table

Use the drop-down list to select the foreign table.

The Foreign Table Columns area allows you to select the column(s) of the Foreign table.

To select a column, you need to move it from the Available Columns list to the Included Columns list. Use the Move to Selected Move to Available buttons or drag-and-drop operations to move the column from one list to another.

If the referenced column(s) are changed frequently, it may be wise to add an index to the foreign key column so that referential actions associated with the foreign key column were performed more efficiently. See Indexes for details.

On Update action / On Delete action

  • No action

Produce an error indicating that the deletion or update would create a foreign key constraint violation. If the constraint is deferred, this error will be produced at constraint check time if there still exist any referencing rows. This is the default action.

  • Restrict

Produce an error indicating that the deletion or update would create a foreign key constraint violation. This is the same as NO ACTION except that the check is not deferrable.

  • Cascade

Delete any rows referencing the deleted row, or update the value of the referencing column to the new value of the referenced column, respectively.

  • Set NULL

Set the referencing column(s) to null.

  • Set default

Set the referencing column(s) to their default values.

Match type

A value inserted into the referencing column(s) is matched against the values of the referenced table and referenced columns using the given match type. These are the available match types:

RadioButton Simple

Allows some foreign key columns to be null while other parts of the foreign key are not null (MATCH SIMPLE).

RadioButton Full

Does not allow one column of a multicolumn foreign key to be null unless all foreign key columns are null (MATCH FULL).

Deferrable

CheckBox Deferrable

This option controls whether the constraint can be deferred. A constraint that is not deferrable will be checked immediately after every command. Checking of constraints that are deferrable may be postponed until the end of the transaction.

Check Time

If a constraint is deferrable, this option specifies the default time to check the constraint:

Immediate

If the constraint is INITIALLY IMMEDIATE, it is checked after each statement.

Deferred

If the constraint is INITIALLY DEFERRED, it is checked only at the end of the transaction.


Checks

A check specifies an expression producing a Boolean result which new or updated rows must satisfy for an insert or update operation to succeed. Expressions evaluating to TRUE or UNKNOWN succeed. Should any row of an insert or update operation produce a FALSE result an error exception is raised and the insert or update does not alter the database. A check constraint specified as a column constraint should reference that column's value only, while an expression appearing in a table constraint may reference multiple columns.

Table checks are managed within the Checks tab of Table Editor.

Creating Checks

  • open the table in Table Editor;
  • proceed to the Checks tab there;
  • right-click the tab area and select the New Check context menu item, or press the Ins key;
  • define the check properties using the Check Editor dialog.

Editing Checks

  • open the table in Table Editor;
  • proceed to the Checks tab there;
  • right-click the check and select the Edit Check <check_name> context menu item, or simply double-click the check;
  • edit the check properties using the Check Editor dialog.

Dropping Checks

  • open the table in Table Editor;
  • proceed to the Checks tab there;
  • right-click the check and select the Drop Check <check_name> context menu item;
  • confirm dropping in the dialog window.


Check Editor

Check Editor allows you to specify check definition and set check properties. It opens automatically when you create a new check and is available on editing an existing one (see Create check and Edit check for details).

To open a check constraint in Check Editor, double-click it in the DB Explorer tree, or use the Edit Check... item of the context menu within the Checks tab of Table Editor.

  • Editing check definition


Editing check definition

Use the Check tab of Check Editor to create/edit a check constraint and specify its properties.

Check name

Enter a name for the new check, or modify the name of the check being edited.

Check Editor - Editing check definition

CheckBox Not validated (for Postgres 9.2 and higher)

If this option is selected then a check can initially be added to a large existing table without checking its initial contents, but new tuples must comply with it.

CheckBox Non-inheritable (for Postgres 9.2 and higher)

If this option is selected then a check will not propagate to child tables.

Condition

This area represents the condition implied by the check constraint.

You can specify any logical (Boolean) expression that returns TRUE or FALSE based on the logical operators. For example, salary >= 15000 AND salary <= 100000.

The Description field allows you to view and edit the comment for the object.

For your convenience the syntax highlight, code completion and a number of other features for efficient SQL editing are implemented. For details see Working with Query Data area and Using the context menu.


Indexes

Indexes are objects used to find rows with specific column values quickly. If a table has an index for the columns in question, PostgreSQL can quickly determine the position to seek to in the middle of the data file without having to look at all the data.

Table indexes are managed within the Indices tab of Table Editor.

Creating Indexes

  • open the table in Table Editor;
  • proceed to the Indexes tab there;
  • right-click the tab area and select the New Index context menu item, or press the Ins key;
  • define the index properties using the Index Editor dialog.

Editing Indexes

  • open the table in Table Editor;
  • proceed to the Indexes tab there;
  • right-click the index and select the Edit Index context menu item, or simply double-click the index;
  • edit the index properties using the Index Editor dialog.

Dropping Indexes

  • open the table in Table Editor;
  • proceed to the Indexes tab there;
  • right-click the index and select the Drop Index context menu item;
  • confirm dropping in the dialog window.


Index Editor

Index Editor allows you to specify index definition and set index properties. It opens automatically when you create a new index and is available on editing an existing one (see Create Index and Edit Index for details).

To open an index in Index Editor, double-click it in the DB Explorer tree, or use the Edit Index... item of the context menu within the Indices tab of Table Editor.

  • Using Navigation bar and Toolbar
  • Editing index definition
  • Editing index description
  • Viewing DDL definition


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Index Editor.

Object

iconDB select a database

select an index for editing

General

iconCompile compile the index (if it is being created/modified)

iconSaveDescription save the index description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the index

view the dependency tree for the index

reindex the current table index

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the index:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Editing index definition

Use the Index tab of Index Editor to create/edit an index on a specified table or materialized view, and specify index properties.

Name

Enter a name for the new index, or modify the name of the index being edited.

For table or materialized view

The drop-down list of tables and materialized views allows you to select the object to be indexed (available on creating a new index).

Index type

RadioButton Primary key - this selection indicates that the primary key index is created.

RadioButton Unique key - this selection indicates that the unique key index is created.

RadioButton Unique index - makes index unique, causes the system to check for duplicate values in the table when the index is created (if data already exist) and each time data is added.

RadioButton Index - this selection specifies a regular, non-unique index.

RadioButton Exclusion - this selection specifies that the exclusion constraint is created. It ensures that if any two rows are compared on the specified columns or expressions using the specified operators, at least one of these operator comparisons will return false or null.

CheckBox Mark for table cluster

This option selects the index as default for future CLUSTER operations. It does not actually re-cluster the table (ALTER TABLE ... CLUSTER ON ...).

Deferrable

If Primary or Unique key is selected as Index type, this section appears. It controls whether the index can be deferred. A constraint that is not deferrable will be checked immediately after every command.

CheckBox Deferrable

Check this option to defer the index.

Check Time

If a constraint is deferrable, this option specifies the default time to check the constraint:

Immediate - it is checked after each statement.

Deferred - it is checked only at the end of the transaction.

Index Editor - Editing index definition

CheckBox Don't lock table on creation

Use this option to build the index without taking any locks that prevent concurrent inserts, updates, or deletes on the table.

Tablespace

Use the drop-down list to specify the index storage (a tablespace).

Index method

Select the index type. PostgreSQL provides several index methods: B-tree, R-tree, hash, GiST (Generalized Index Search Trees), SP-GiST (space-partitioned GiST for Postgres 9.2 and higher), brin (Block Range INdex for Postgres 9.5 and higher).

The B-tree index method is an implementation of Lehman-Yao high-concurrency B-trees.

The R-tree index method implements standard R-trees using Guttman's quadratic split algorithm.

The hash index method is an implementation of Litwin's linear hashing.

CheckBox Use default fillfactor

Check this option to set fillfactor value to 100.

Fillfactor

Specify the custom fillfactor value in this field.

Note: To set this value you need to uncheck CheckBox Use default fillfactor option.

B-tree index method

CheckBox Use default deduplicate items

This option is available for B-tree method only. It controls usage of the B-tree deduplication technique for work optimization. If enabled, it applies the default value.

CheckBox Deduplicate_items

Sets the value for inserts from triggering deduplication.

GIN index method

CheckBox Use default fast update

This option is available for Gin method only. Enable this setting to control the usage of the fast update technique. If enabled, it applies the value set below by default.

CheckBox Fastupdate

Set this option ON to improve update speed or OFF otherwise.

CheckBox Use default gin_pending_list_limit

This option is available for Gin method only. Enable this setting to control the limit to move entries to the main GIN data structure. If enabled, it applies the default value (4Mb).

CheckBox Gin_pending_list_limit

This value is specified in kilobytes. If the pending list becomes larger than this value, the entries are moved to the main GIN data structure using the same bulk insert techniques used during initial index creation.

GIST index method

CheckBox Use default buffering

This option is available for Gist method only. It controls whether to use the buffered build technique to build the index. If enabled, it applies the value set by default.

CheckBox Buffering

If it's OFF the buffering is disabled, ON it is enabled, and with AUTO it is initially disabled, but is turned on on-the-fly once the index size reaches effective_cache_size.

BRIN index method

CheckBox Use default pages_per_range

This option is available for Brin method only. It controls whether the default value must be applied.

CheckBox Pages_per_range

It defines the number of table blocks that make up one block range for each entry of an index.

CheckBox Use default autosummarize

This option is available for Brin method only. It applies the default value fo autosummarizing.

CheckBox Autosummarize

Enables summarization is queued for the previous page range whenever an insertion is detected on the next one. Whenever autovacuum runs in that database, summarization will occur for all unsummarized page ranges that have been filled.

Condition for partial index

A partial index is an index that contains entries for only a portion of a table, usually a portion that is more useful for indexing than the rest of the table. If you wish to create partial index, enter conditional expression in this edit box.

Index keys

To include column(s) in the index, you need to move it from the Available Columns list to the Index Keys list. Use the Items - Move to Selected Items - Move all to Selected Items - Move all to Available Items - Move to Available buttons or drag-and-drop operations to move the columns from one list to another.

Operator Class

This column allows you to specify an operator class for each column of the index. Use the drop-down list to select the operator class identifying the operators to be used by the index for the column.

Selected index key

Specifies an index key name or an expression based on one or more index key columns of the table. This feature is useful to obtain fast access to tables based on the results of computations.


Policies

A policy grants the permission to select, insert, update, or delete rows that match the relevant policy expression.

Table policies are managed within the Policy tab of Table Editor.

Creating Policies

To create a new policy:

  • open the table in Table Editor;
  • proceed to the Policies tab there;
  • right-click the tab area and select the New Policy context menu item, or press the Ins key;
  • define the policy properties using the Policy Editor dialog.

Editing Policies

To view an existing policy:

  • open the table in Table Editor;
  • proceed to the Policies tab there;
  • right-click the policy and select the Edit Policy <policy_name> context menu item, or simply double-click the policy;
  • edit the policy properties using the Policy Editor dialog.

Dropping Policies

To drop a policy:

  • open the table in Table Editor;
  • proceed to the Policies tab there;
  • right-click the policy and select the Drop Policy <policy_name> context menu item;
  • confirm dropping in the dialog window.


Editing Policy Definition

Use the Policies tab of Policy Editor to create/edit a policy and specify its properties.

Policy name

Enter a name for the new policy, or modify the name of the policy being edited. Policy names are per-table. Therefore, one policy name can be used for many different tables and have a definition for each table which is appropriate to that table.

For table

Select a table to create a policy for.

Command

Select the command to which the policy applies: ALL, SELECT, INSERT, UPDATE, or DELETE.

Roles

Move the roles from Available to Selected to which the policy is to be applied.

Table Editor - Policy editor

Using expression

Use this field to define an SQL conditional expression to be added to queries that refer to the table if row level security is enabled. Rows for which the expression returns true will be visible. Any rows for which the expression returns false or null will not be visible to the user (in a SELECT), and will not be available for modification (in an UPDATE or DELETE).

Check expression

Use this field to define an SQL conditional expression. It's only available for INSERT and UPDATE commands. Only the rows satisfying the expression will be allowed.

The Description field allows you to view and edit the comment for the policy.

After all properties have been set you can enable or force row level security for the table on the Policies tab using the corresponding options:

CheckBox Enable row level security

Use this option to apply the policies to the table.

CheckBox Force row level security

With this option ON, row level security policies will be applied when the user is the table owner. If disabled then row level security will not be applied when the user is the table owner.

Table Editor - Policies Common Options


Views

A View is a logical table based on one or more tables or views. A view contains no data itself. The tables upon which a view is based are called base tables.

Views are useful for allowing users to access a set of relations (tables) as if it were a single table, and limiting their access to just that. Views can also be used to restrict access to rows (a subset of a particular table).

View Editor allows you to create new views and define their properties (view name and the SELECT statement it implements). It opens automatically when you create a new view and is available on editing an existing one. SQL Manager supports manual creating and editing of Materialized views.

Hint: A view can be created by building a query in Visual Design Query (click the Create view Navigation bar item after building).

  • Using Navigation bar and Toolbar
  • Creating/editing view
  • Managing columns
  • Managing indexes
  • Managing rules
  • Managing triggers
  • Browsing object dependencies
  • Working with data
  • Editing view description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in View Editor.

View Editor - Using Navigation barNEW

Object

iconDB select a database

select a view for editing

General

iconCompile compile the view (if it is being created/modified)

iconSaveDescription save the view description (if it has been modified)

edit the view query using Design Query

iconRefresh refresh the content of the active tab

iconPrint print metadata of the view

view the dependency tree for the view

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the view:

Rules

add a new rule

edit selected rule

drop selected rule(s)

Triggers

add a new trigger

edit selected trigger

drop selected trigger(s)

Data Management

iconCommit commit transaction

iconRollback rollback transaction

Note: These actions are available if the CheckBox Use transactions in object editors, Query Data and Design Query option is checked in the Database Registration Info | Data options dialog.

export data from the view using Export Data Wizard

export data from the view as SQL script using Export as SQL Script Wizard

import data

Materialized View

View Editor - Mat view refresh refreshes data of materialized view

View Editor - Mat view clear clears data of materialized view

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing view

Use the View tab of View Editor to create/edit a view and specify its definition.

This tab represents the view definition as SQL statement, hence it is enough to simply edit the whole definition using the editor area to make appropriate changes, and recompile the view.

For your convenience the syntax highlight, code completion and a number of other features for efficient SQL editing are implemented. For details see Working with Query Data area and Using the context menu.

View Editor - Editing view definition

Note: The visual representation of a view can be easily created using the Visual Design Query.

Note: You can create Materialized views manually.

To compile a view, you can use the iconCompile Compile item available within the Navigation bar or toolbar.


Managing columns

The Columns tab is provided for viewing columns represented in the view.

Right-click a column to display the context menu allowing you to rename the selected column, export column name list or copy it to clipboard.

View Editor - Viewing fields

The Columns list provides the following attributes of each column of the view:

Column Name

Column Type

Description

For details see Columns.

If necessary, you can also use the Column Description area to supply a description for each column.


Managing indexes

The Indices tab is provided for managing indices for the Materialized views only. Double-click an index to open Index Editor for editing the index.

Right-click the area to display the context menu allowing you to Create new, Edit, Rename, Drop, Reindex the selected index, or Reindex all indices. Using the menu you can also export the list of the table indices to any of the supported formats.

Indices management tools are also available through the Navigation bar and toolbar of View Editor.

If necessary, you can also use the Index Description area below to supply a description for each index.

View Editor - Managing indices

NOTE: This tab is only available for materialized views.


Managing rules

The Rules tab is provided for viewing rules specified for the view. Double-click a rule to open Rule Editor for editing the rule.

Right-click a rule to display the context menu allowing you to create new, edit, or drop the selected rule. Using the menu you can also export the list of the view rules to any of supported formats.

View Editor - Managing view rules

The Rules list provides the following attributes of each rule of the view:

Rule Name

Event

Instead

WHERE condition

For details see Rules.

If necessary, you can also use the Rule Description area to supply a description for each rule.


Managing triggers

The Triggers tab is provided for managing table triggers. Double-click a trigger to open Trigger Editor for editing the trigger.

Right-click the area to display the context menu allowing you to create new, edit, drop, enable/disable the selected trigger, or enable/disable all triggers. Using the menu you can also export the list of the table triggers to any of supported formats.

Triggers management tools are also available through the Navigation bar and toolbar of View Editor.

View Editor - Managing triggers

The Triggers list provides the following attributes of each trigger of the table:

Trigger Name

Moment

Event

Function

Disabled

Arguments

For details see Triggers.

If necessary, you can also use the Trigger Description area to supply a description for each trigger.


Working with data

The Data tab displays the view data as a grid by default (see Data View for details). The context menu of this tab and the Navigation bar allow you to Export Data, Import Data, Export as SQL Script.

While working with view data, you are provided with a number of filtering and grouping facilities.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Data management tools are also available through the Navigation bar and toolbar of View Editor.

View Editor - Working with data

For Materialized views the following operations are available on the Navigation bar or Toolbar:

View Editor - Mat view refresh refreshes data of materialized view

View Editor - Mat view clear clears data of materialized view (REFRESH with NO DATA)

See also:

Working with table data

Data View


Functions

A Function is a mapping embodied as a program (the function body) that can be invoked by using zero or more input values (arguments) to a single value (the result). A Function can be stored as a database object providing reusable code.

PostgreSQL provides four kinds of functions:

  • query language functions (functions written in SQL);
  • procedural language functions (functions written in, for example, PL/Tcl or PL/pgSQL);
  • internal functions;
  • C-language functions.

Every kind of function can take base types, composite types, or combinations of these as arguments (parameters). In addition, every kind of function can return a base type or a composite type. Many kinds of functions can take or return certain pseudo-types (such as polymorphic types), but the available facilities vary.

Function Editor allows you to define function properties. It opens automatically when you create a new function and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing function
  • Executing functions
  • Specifying input parameters
  • Browsing object dependencies
  • Editing function description
  • Viewing DDL definition
  • Debugger


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Function Editor.

Procedure Editor - Navigation bar

The Navigation bar of Function Editor allows you to:

Object

iconDB select a database

select a function for editing

General

iconCompile compile the function (if it is being created/modified)

iconSaveDescription save the function description (if it has been modified)

iconCheckSyntax check function syntax

iconDebug debug the function using Function debugger

debugwithextension debug with pldbgapi extension

iconExecute execute the function

iconRefresh refresh the content of the active tab

iconPrint print metadata of the function

view the dependency tree for the function

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the function:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing function

Use the Function tab of Function Editor to create/edit a function and specify its definition.

Name

Select a schema and enter a name for the new function, or modify the name of the function being edited.

Function Editor - Editing function definition

Returns

Use this options to define what data is to return by the function:

RadioButton Single value - the function returns a single item; to define its type use the drop-down list.

RadioButton Set of values - the function returns a set of items; define its type using the drop-down list.

RadioButton Table - the function returns table; define its type using the Return table column (for Postgres 9.1 and higher).

RadioButton Nothing - the function returns void.

RadioButton Trigger - the function returns a trigger.

The Arguments list provides the following attributes of each argument used in the function:

Name

Type (the argument data type)

Mode (in, out, in/out)

Default value

Set the function arguments by right-clicking in the list and selecting iconPlus Add Argument. Once the argument is added, select its type from the Argument Type drop-down list. To delete the existing argument, select iconMinus Delete Argument from the popup menu. To reorder the arguments within the list, use the btnArrowUp Move Up and btnArrowDown Move Down items or the corresponding Ctrl+Up/Ctrl+Down shortcuts.

It is possible to set the argument names for server version 8.0 and higher.

Hint: You can reorder arguments in the list using the Move Up and Move Down popup menu items.

Language

Select the language that the function is implemented in: SQL, C, internal, or the name of a user-defined procedural language.

CheckBox Returns NULL on NULL input

This option indicates that the function always returns null whenever any of its arguments are null. If this parameter is specified, the function is not executed when there are null arguments; instead a null result is assumed automatically.

CheckBox Execute with definer's privileges

This option specifies that the function is to be executed with the privileges of the user that created it. Otherwise, the function is to be executed with the privileges of the user that calls it.

CheckBox Is window function

This option indicates that the function is a window function rather than a plain function. A window function performs a calculation across a set of table rows that are somehow related to the current row.

CheckBox Is leakproof function

This option indicates that the function has no side effects. It reveals no information about its arguments other than by its return value. For example, a function which throws an error message for some argument values but not others, or which includes the argument values in any error message, is not leakproof.

Optimization

Select the behaviour of the function:

IMMUTABLE indicates that the function cannot modify the database and always returns the same result when given the same argument values.

STABLE indicates that the function cannot modify the database, and that within a single table scan it will consistently return the same result for the same argument values, but that its result could change across SQL statements.

VOLATILE indicates that the function value can change even within a single table scan, so no optimizations can be made.

Parallel

Set whether the function can be executed in the parallel mode:

UNSAFE value prohibits parallel mode.

RESTRICTED indicates that the function can be executed in parallel mode, but the execution is restricted to parallel group leader.

SAFE value indicates that the function can be run in parallel mode.

Planner options

This group is available for server version 8.3 and higher. The spinner controls allow you to specify Estimated execution cost and Estimated number of rows.

Definition

This area allows you to set the function definition (body).

For your convenience the syntax highlight, code folding, using macro and a number of other features for efficient SQL editing are implemented. For details see Working with Query Data area, Using the context menu and .

The possibility to use macros is also implemented.

To start recording a macro, click the btnRecordMacro Record button available in the status bar area, or use the Shift+Ctrl+R shortcut.

To stop recording, click the btnStopRecordMacro Stop button, or use the Shift+Ctrl+R shortcut.

To call the recorded macro, use the btnPlayMacro Play button, or use the Shift+Ctrl+P shortcut.

To execute the function, you can use the btnExecuteQuery Execute item available within the Navigation bar or toolbar.


Setting configuration parameters

Use the Configuration Parameters tab to set function or procedure configuration parameters.

Function Editor - Setting configuration parameters

Configuration parameter is set to the specified value when the function\procedure is entered, and then restored to its prior value on exiting.

Use the Parameter Name list to select settable run-time parameters.

Parameter Value

Enter a new value of parameter. Values can be specified as string constants, identifiers, numbers, or comma-separated lists of these, as appropriate for the particular parameter.

If the Take Current Value option is checked for a particular parameter then the session's current value of the parameter is saved as the value to be applied when the function\procedure is entered.


Executing functions

Function Editor provides an ability to execute functions. Click the btnExecuteQuery Execute item of the Navigation bar or use the corresponding toolbar button to execute the function.

If the function has input parameters, SQL Manager allows you to specify the values for these parameters in the Input Parameters dialog, which appears just before execution.

The result of the successfully executed function, as well as the error message in case of execution failure, appears in the message panel at the bottom of the Function Editor window.

Note: If any unsaved changes are applied to the stored function being currently edited, the execution of the function is impossible unless changes are saved through the Compile item of the Navigation bar.

See also:

Specifying input parameters


Specifying input parameters

If the stored function has parameters, the Enter Parameter values dialog appears before the function execution. This dialog is provided for browsing the list of parameters of the function and allows you to specify the values for all function parameters. After changes are done, click the OK button to execute the stored function, or the Cancel button to abort the execution.

Function Editor - Specifying input parameters


Debugger

To fix the errors in the function or procedure code and to optimize its work, you can debug the function or procedure step-by-step before compilation, using the Debugger.

To activate the debugger, open the function or procedure in the Editor, then click the iconDebug Debug button on the toolbar or on the Navigation bar.

NB You can use debugwithextension Debug with extension button to debug with server pldbgapi extension. In this case you will be able to use Step into feature, which is not available in the built-in program debugger. To install the extension use Services --> Database extensions.

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in the Debugger.

Function debugger - Using Navigation bar

General

iconRestoreDefaultSize restore the default size and position of the debugger window

Debug

iconCommit commit retaining

iconDebug step over the next statement

stepinto step into the statement. Available if Debug with extension used

iconExecute run the function\procedure

run the function\procedure to cursor

toggle breakpoint at the current statement

reset function\procedure execution

Items of the Navigation bar are also available on the ToolBar of Function Debugger. To enable the toolbar, open the Environment Options dialog, proceed to the Windows section there and select RadioButton Toolbar (if you need the toolbar only) or RadioButton Both (if you need both the toolbar and the Navigation bar) in the Bar style for child forms group.


Debugging

The working area allows you to view the text of object definition.

The red spots ( [image] ) at the left of the workspace and red highlight stand for breakpoints;

the green arrow ( btnArrowRight ) and blue highlight indicate the currently executed statement.

Function debugger - Debugging function

For your convenience the following shortcuts are implemented:

  • To start executing step-by-step, press F8.
  • To reset the execution, press the Ctrl+F2 key combination.
  • To add/remove a breakpoint to/from the current statement, press the Ctrl+F8 key combination.
  • To run the function\procedure (to the end or to the next breakpoint) press F9.

Set mouse cursor over a parameter to see a hint with its current value.

Hint: Click an embedded function (or any other object) name with the Ctrl key pressed to open the object in its editor. For details see Using object links.

NB: stepinto Step into button is only available if Debug with extension used

The lower area of the Debugger window allows you to browse parameters and variables, results, last statement, breakpoints, messages. For details see Browsing debug information.


Browsing debug information

Use tabs at the bottom of the debugger window to view miscellaneous debug information.

Parameters and Variables

This tab displays the list of input and output parameters and variables (distinguished by respective icons) with their values and types.

Function debugger - Debug info - Parameters and variables

Double-click an item in the list to call the Modify variable dialog allowing you to set the parameter/variable type and value.

Function debugger - Debug info - Parameters and variables - Modify variable

Variable Type

Select the data type to be applied to the variable being edited:

RadioButton Numeric

RadioButton String

RadioButton Boolean

RadioButton Date and Time

Use the Value box below to specify a value for the variable, or select the CheckBox Null option. The control varies according to the selected data type. For your convenience the Calculator and Date editor are implemented for Numeric and Date and Time types respectively: click the arrow-down button to call the Calculator / Date editor popup window.

Results

This tab displays the function execution results.

Function debugger - Debug info - Results

Last Statement

This tab displays the last executed statement, the statement execution plan and the execution time.

Function debugger - Debug info - Last statement

Breakpoints

This tab displays the function breakpoints: the breakpoint line, statement and the number of its passes.

Function debugger - Debug info - Breakpoints

Messages

This tab displays various Debugger messages and errors (if any).

Function debugger - Debug info - Messages


Procedures

A Procedure is a part of code, which performs the row of actions, but doesn't return any values. One of the main features of procedures is using transaction in code. Procedures are supported in PostgreSQL server versions starting from 11.0.

You can create or edit existing procedures in Procedure editor.

Using Navigation bar and Toolbar

Creating/editing procedure

Setting configuration parameters

Specifying input parameters

Browsing object dependencies

Editing procedure description

Viewing DDL definition

Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Procedure Editor.

Procedure Editor - Navigation bar

The Navigation bar of Procedure Editor allows you to:

Object

iconDB select a database

select a procedure for editing

General

iconCompile compile the procedure (if it is being created/modified)

iconSaveDescription save the procedure description (if it has been modified)

iconCheckSyntax check procedure syntax

iconDebug debug the procedure using debugger

iconExecute execute the function

iconRefresh refresh the content of the active tab

iconPrint print metadata of the function

view the dependency tree for the function

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the procedure:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing procedure

Use the Procedure tab of Procedure Editor to create/edit a procedure and specify its definition.

Name

Select a schema and enter a name for the new procedure, or modify the name of the procedure being edited.

Procedure Editor - Editor

Language

Select the language that the procedure is implemented in: SQL, C, internal, or the name of a user-defined procedural language.

The Arguments list provides the following attributes of each argument used in the function:

Name

Type (the argument data type)

Mode (in, out, in/out)

Default value

Set the procedure arguments by right-clicking in the list and selecting iconPlus Add Argument. Once the argument is added, select its type from the Argument Type drop-down list. To delete the existing argument, select iconMinus Delete Argument from the popup menu. To reorder the arguments within the list, use the btnArrowUp Move Up and btnArrowDown Move Down items or the corresponding Ctrl+Up/Ctrl+Down shortcuts.

Definition

This area allows you to set the procedure definition (body).

For your convenience the syntax highlight, code folding, using macro and a number of other features for efficient SQL editing are implemented. For details see Working with Query Data area, Using the context menu and .

To execute the function you can use the btnExecuteQuery Execute item available within the Navigation bar or toolbar.


Domains

A Domain is based on a particular base type and for many purposes is interchangeable with its base type. However, a domain may have constraints that restrict its valid values to a subset of what the underlying base type would allow.

Domain Editor allows you to define domain properties. It opens automatically when you create a new domain and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing domain
  • Managing domain checks
  • Browsing object dependencies
  • Editing domain description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Domain Editor.

Domain Editor - Using Navigation bar

Object

iconDB select a database

select a domain for editing

General

iconCompile compile the domain (if it is being created/modified)

iconSaveDescription save the domain description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the domain

view the dependency tree for the domain

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the domain:

Checks

add a new check

edit selected check

drop selected check(s)

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Managing domain checks

The Checks tab is provided for managing domain checks. Double-click a check to call Check Editor for editing the check. A right-click displays the context menu allowing you to create a new, edit, or drop the selected check.

Domain Editor - Managing domain checks

See Checks for details.


Creating/editing domain

Use the Domain tab of Domain Editor to create/edit a domain and specify its definition.

Name

Select a schema and enter a name for the new domain, or modify the name of the domain being edited.

Domain Editor - Editing domain definition

Data type

Select the underlying data type of the domain from the drop-down list, and set its size, precision, if required for the selected data type. To create an array of the chosen type, use the Number of array dimensions spinner control.

Advanced

CheckBox Not Null

If enabled, specifies that values of this domain are not allowed to be null.

Default value

This specifies a default value for columns of the domain data type. The value is any variable-free expression (but subqueries are not allowed). The data type of the default expression must match the data type of the domain. If no default value is specified, then the default value is the null value.

The default expression will be used in any insert operation that does not specify a value for the column. If a default value is defined for a particular column, it overrides any default associated with the domain. In turn, the domain default overrides any default value associated with the underlying data type.


Rules

The Rule system modifies queries to take rules into consideration, and then passes the modified query to the query planner for planning and execution. It is very powerful, and can be used for many things such as query language procedures, views, and versions.

Rule Editor allows you to define rule properties. It opens automatically when you create a new rule and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing rule
  • Browsing object dependencies
  • Editing rule description
  • Viewing DDL definition


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Rule Editor.

Rule Editor - Using Navigation bar

Object

iconDB select a database

select a rule for editing

General

iconCompile compile the rule (if it is being created/modified)

iconSaveDescription save the rule description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the rule

view the dependency tree for the rule

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the rule:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing rule

Use the Rule tab of Rule Editor to create/edit a rule and specify its definition.

Name

Enter a name for the new rule, or modify the name of the rule being edited.

For table or view

Use the drop-down list to select the table/view the rule applies to.

CheckBox Instead

This option indicates that the commands should be executed instead of the original command.

Rule Editor - Editing rule definition

Event

Use the drop-down list to select the rule event: SELECT, UPDATE, INSERT, DELETE.

Condition

Specify the condition that defines the rule using arithmetic and relational operators. This can be any SQL conditional expression (returning boolean). The condition expression may not refer to any tables except NEW and OLD, and may not contain aggregate functions.

Action

This area represents the action(s) to be taken upon the specified event occurrence. Specify the command or commands that make up the rule action. Valid commands are SELECT, INSERT, UPDATE, DELETE, or NOTIFY.

For your convenience the syntax highlight, code folding and a number of other features for efficient SQL editing are implemented. For details see Working with Query Data area and Using the context menu.

The possibility to use macros is also implemented.

To start recording a macro, click the btnRecordMacro Record button available in the status bar area, or use the Shift+Ctrl+R shortcut.

To stop recording, click the btnStopRecordMacro Stop button, or use the Shift+Ctrl+R shortcut.

To call the recorded macro, use the btnPlayMacro Play button, or use the Shift+Ctrl+P shortcut.


Triggers

A trigger is a special kind of stored procedure that automatically executes when an event occurs in the database.

Data manipulation language triggers are executed in response to user's attempts to change data with the help of DML. DML events include INSERT, UPDATE and DELETE operations which can be applied to a table.

Table triggers are managed within the Triggers tab of Table Editor.

Trigger Editor allows you to specify trigger definition and set trigger properties. It opens automatically when you create a new trigger and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Editing trigger definition
  • Browsing object dependencies
  • Editing trigger description
  • Viewing DDL definition


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Trigger Editor.

Trigger Editor - Using Navigation bar

Object

iconDB select a database

select a trigger for editing

General

iconCompile compile the trigger (if it is being created/modified)

iconSaveDescription save the trigger description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the trigger

view the dependency tree for the trigger

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the trigger:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Editing trigger definition

Use the Trigger tab of Trigger Editor to create/edit a table trigger and specify its properties.

Name

Enter a name for the new trigger, or modify the name of the trigger being edited.

CheckBox Enabled

Enables/disables the trigger immediately after it is created.

For table or view

The drop-down list of tables and views allows you to select the table on which the trigger is executed.

Trigger Editor - Editing trigger definition

Constraint

Check this option to create a constraint trigger with adjusted timing of firing. A constraint trigger can only be of After Row type.

CheckBox Referenced table

Select the table for the trigger.

CheckBox Deferrable

This option controls whether the trigger can be deferred. Set this option to fire the trigger at the end of the containing transaction, otherwise it's fired at the end of the statement causing the triggering event.

Check time

This option specifies the default timing of the trigger: deferred trigger can be fired immediately or can be deferred.

Type

Select the trigger behaviour type:

RadioButton Before

Specifies that the trigger is fired before the event.

RadioButton After

Specifies that the trigger is fired after the event.

For each

This specifies whether the trigger procedure should be fired once for every row affected by the trigger event, or just once per SQL statement.

On event

Specify the data modification statements that activate the trigger when it is tried against this table: Insert, Update, Delete or Truncate (ON TRUNCATE is supported only from PostgreSQL version 8.4). At least one option must be specified.

Updated columns

From this drop-down list you can select the columns that will be updated.

Condition

Define statement for WHEN condition of the trigger.

Function

A user-supplied function that is declared as taking no arguments and returning type trigger, which is executed when the trigger fires. You can use already existing function or create new one.

Arguments

This area allows you to specify an optional list of arguments to be provided to the function when the trigger is executed. The arguments are literal string constants. Simple names and numeric constants may be written here, too, but they will all be converted to strings.

Trigger Editor - Editing trigger definition - Arguments

Set the arguments by right-clicking in the list and selecting iconPlus Add argument from the context menu (or by pressing the corresponding button). After the argument is added, set its value in the Argument Value field. To delete the existing argument, select iconMinus Delete argument from the context menu (or press the corresponding button).

To change the arguments order, use the Move Up / Move Down context menu items or the btnMoveUp btnMoveDown buttons.

The Definition area below specifies the trigger conditions and actions that determine whether the tried DML statements cause the trigger actions to be performed. The trigger actions take effect when the DML operation is performed.


Sequences

Sequence objects (also called sequence generators or just sequences) are special single-row tables. A sequence object is usually used to generate unique identifiers for rows of a table.

Sequence Editor allows you to define sequence properties. It opens automatically when you create a new sequence and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing sequence
  • Browsing object dependencies
  • Editing sequence description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Sequence Editor.

Sequence Editor - Using Navigation bar

Object

iconDB select a database

select a sequence for editing

General

iconCompile compile the sequence (if it is being created/modified)

iconSaveDescription save the sequence description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the sequence

view the dependency tree for the sequence

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the sequence:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing sequence

Name

Select a schema and enter a name for the new sequence, or modify the name of the sequence being edited.

Sequence Editor - Editing sequence definition

Next Value (Start value - when creating a new sequence)

This option defines the sequence value to begin from. The default starting value is Min value for ascending sequences and Max value for descending ones.

Increment

Specifies which value is added to the current sequence value to create a new value. A positive value will make an ascending sequence, a negative one a descending sequence. The default value is 1.

Min Value

Determines the minimum value a sequence can generate.

Max Value

Determines the maximum value for the sequence.

Cache

Specifies how many sequence numbers are to be preallocated and stored in memory for faster access. The minimum value is 1 (only one value can be generated at a time, i.e., no cache).

CheckBox Temporary

If specified, the sequence object is created only for this session, and is automatically dropped on session exit. Existing permanent sequences with the same name are not visible (in this session) while the temporary sequence exists, unless they are referenced with schema-qualified names.

CheckBox Cycle

This option allows the sequence to wrap around when the maxvalue or minvalue has been reached by an ascending or descending sequence respectively. If the limit is reached, the next number generated will be the minvalue or maxvalue, respectively. Otherwise, any calls to nextval after the sequence has reached its maximum value will return an error.


Base Types

A Type is internally represented as an existing type, but is considered to be a separate data type.

Base types are those, like int4, that are implemented below the level of the SQL language (typically in a low-level language such as C). They generally correspond to what are often known as abstract data types. PostgreSQL can only operate on such types through functions provided by the user and only understands the behavior of such types to the extent that the user describes them. Base types are further subdivided into scalar and array types. For each scalar type, a corresponding array type is automatically created that can hold variable-size arrays of that scalar type.

Base Type Editor allows you to define base type properties. It opens automatically when you create a new base type and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing base type
  • Browsing object dependencies
  • Editing base type description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Base Type Editor.

Base Type Editor - Using Navigation bar

Object

iconDB select a database

select a base type for editing

General

iconCompile compile the base type (if it is being created/modified)

iconSaveDescription save the base type description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the base type

view the dependency tree for the base type

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the base type:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing base type

The Base Type tab of Base Type Editor allows you to view/edit the base type properties.

Name

Select a schema and enter a name for the new base type, or view the name of the base type being edited.

Base Type Editor - Editing base type definition

Synonym

Set the type synonym (available for older server versions).

Input function

Use the drop-down list to select the function that will convert data from the type's external textual form to its internal form.

Output function

Use the drop-down list to select the function that will convert data from the type's internal form to its external textual form.

Internal length

This value specifies the length (in bytes) of the new type's internal representation. Use the spinner control to set a value or check the CheckBox Variable option to apply variable-length (default assumption).

External length

This value specifies the length (in bytes) of the new type's external representation. Use the spinner control to set a value or check the CheckBox Variable option if the type length is unknown (for server version 7.3 and lower only).

Analyze function

Use the drop-down list to select the function that will perform statistical analysis for the data type.

Receive function

Use the drop-down list to select the function that will convert data from the type's external binary form to its internal form.

Send function

Use the drop-down list to select the function that will convert data from the type's internal form to its external binary form.

Element

If the type being created is an array, use the drop-down list to specify the type of the array elements.

Default

If necessary, specify the default value for the data type. By default the NULL value is applied.

Alignment

Use the drop-down list to select the storage alignment requirement of the data type: char, int2, int4, or double.

Delimiter

If necessary, specify the delimiter character to be used between values in arrays made of this type.

Storage

Use the drop-down list to select the storage strategy for the data type: PLAIN, MAIN, EXTERNAL, EXTENDED.

CheckBox Passed by value

This option indicates that values of this data type are passed by value rather than by reference.


Composite Types

A Type is internally represented as an existing type, but is considered to be a separate data type.

Composite types, or row types, are created whenever the user creates a table; it is also possible to define a "stand-alone" composite type with no associated table. A composite type is simply a list of types with associated field names. A value of a composite type is a row or record of field values. The user can access the component fields from SQL queries.

Composite Type Editor allows you to define composite type properties. It opens automatically when you create a new composite type and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing composite type
  • Browsing object dependencies
  • Editing composite type description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Composite Type Editor.

Composite Type Editor - Using Navigation bar

Object

iconDB select a database

select a composite type for editing

General

iconCompile compile the composite type (if it is being created/modified)

iconSaveDescription save the composite type description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the composite type

view the dependency tree for the composite type

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the composite type:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing composite type

The Composite Type tab of Composite Type Editor allows you to view/edit the composite type properties.

Name

Select a schema and enter a name for the new composite type, or modify the name of the composite type being edited.

Composite Type Editor - Editing composite type definition

Columns

This grid lists the arguments (columns) of the composite type: Name, Type, Size, Precision, Number of array dims.

Right-click within the Columns area to display the context menu allowing you to add new, delete the selected column, or move it up/down within the list.

Name

The name of an attribute (column) for the composite type.

Type

The name of an existing data type to become a column of the composite type.

Size

Specifies the size of the type for this attribute.

Precision

Specifies the precision of the type for this attribute. The precision indicates the number of significant digits.

Number of array dims

Specifies the number of array dimensions (for multidimensional arrays).


Enumerated Types

A Type is internally represented as an existing type, but is considered to be a separate data type.

Enumerated types, or ENUM types, are data types that are comprised of a static, predefined set of values with a specific order. They are equivalent to the enum types in a number of programming languages. An example of an enum type might be the days of the week, or a set of status values for a piece of data.

ENUM Type Editor allows you to define ENUM type properties. It opens automatically when you create a new ENUM type and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing ENUM type
  • Browsing object dependencies
  • Editing ENUM type description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in ENUM Type Editor.

ENUM Type Editor - Using Navigation bar

Object

iconDB select a database

select an enumerated type for editing

General

iconCompile compile the enumerated type (if it is being created/modified)

iconSaveDescription save the enumerated type description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the enumerated type

view the dependency tree for the enumerated type

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the enumerated type:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing ENUM type

The ENUM Type tab of ENUM Type Editor allows you to view/edit the enumerated type properties.

Name

Select a schema and enter a name for the new enumerated type, or modify the name of the enumerated type being edited.

ENUM Type Editor - Editing ENUM type definition

Values

This grid lists the values implied by the enumerated type.

Right-click within the Values area to display the context menu allowing you to add new, delete the selected value, or move it up/down within the list.

Name

Specifies a string representing the textual label associated with one value of the enumerated type.


Range Types

A Type is internally represented as an existing type, but is considered to be a separate data type.

Range types are data types representing a range of values of some element type (called the range's subtype). For instance, ranges of timestamp might be used to represent the ranges of time that a meeting room is reserved. In this case the data type is tsrange (short for "timestamp range"), and timestamp is the subtype. The subtype must have a total order so that it is well-defined whether element values are within, before, or after a range of values.

Range Type Editor allows you to define range type properties. It opens automatically when you create a new range type and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing range type
  • Browsing object dependencies
  • Editing range type description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Range Type Editor.

Range Type Editor - Using Navigation bar and Toolbar

Object

iconDB select a database

select a composite type for editing

General

iconCompile compile the range type (if it is being created/modified)

iconSaveDescription save the range type description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the range type

view the dependency tree for the range type

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the range type:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing range type

The Range Type tab of Range Type Editor allows you to view/edit the range type properties.

Range Type Editor - Editing range type

Name

Select a schema and enter a name for the new range type, or modify the name of the range type being edited.

Subtype

Use the drop-down list to select the subtype. The range type's subtype can be any type with an associated b-tree operator class (to determine the ordering of values for the range type).

If the selected subtype is collatable, and you want to use a non-default collation in the range's ordering, specify the desired collation in the Collation field.

Subtype operator class

If you want to use a non-default operator class, specify its name in this field.

Canonical function

Enter the canonical function name here. This function takes an input range value, and must return an equivalent range value that may have different bounds and formatting.

Subtype difference function

Use the drop-down list to specify the subtype difference function here. This function takes two input values of the subtype, and returns their difference (i.e., X minus Y).

You can use the btnAddFunction button to create a new function or the btnEditFunction button to edit selected function in Function Editor.


Aggregates

Aggregate functions, or Aggregates, perform a calculation on a set of values and return a single value, i.e. compute a single result value from a set of input values.

Aggregate functions in PostgreSQL are expressed as state values and state transition functions. That is, an aggregate can be defined in terms of state that is modified whenever an input item is processed. To define a new aggregate function, one selects a data type for the state value, an initial value for the state, and a state transition function. The state transition function is just an ordinary function that could also be used outside the context of the aggregate. A final function can also be specified, in case the desired result of the aggregate is different from the data that needs to be kept in the running state value.

Aggregate Editor allows you to define aggregate properties. It opens automatically when you create a new aggregate and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing aggregate
  • Browsing object dependencies
  • Editing aggregate description
  • Viewing DDL definition


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Aggregate Editor.

Aggregate Editor - Using Navigation bar

Object

iconDB select a database

select an aggregate for editing

General

iconCompile compile the aggregate (if it is being created/modified)

iconSaveDescription save the aggregate description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the aggregate

view the dependency tree for the aggregate

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the aggregate:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing aggregate

Use the Aggregate tab of Aggregate Editor to create/edit an aggregate function and specify its definition.

Name

Select a schema and enter a name for the new aggregate, or modify the name of the aggregate being edited.

Aggregate Editor - Editing aggregate definition

Input data types

Use this area to specify the input data type(s) on which this aggregate function operates. This can be specified as "ANY" for an aggregate that does not examine its input values (an example is count(*)).

State type

Use the drop-down list to select the data type for the aggregate's state value.

State function

Use the drop-down list to select the name of the state transition function to be called for each input data value. This is normally a function of two arguments, the first being of type state data type and the second of type input data type. Alternatively, for an aggregate that does not examine its input values, the function takes just one argument of type state data type. In either case the function must return a value of type state data type. This function takes the current state value and the current input data item, and returns the next state value.

Final type

Specifies the data type for the aggregate's result value.

Final function

Use the drop-down list to select the name of the final function called to compute the aggregate's result after all input data has been traversed. The function must take a single argument of type state data type. The return data type of the aggregate is defined as the return type of this function. If ffunc is not specified, then the ending state value is used as the aggregate's result, and the return type is state data type.

Initial state

Specifies the initial setting for the state value. This must be a string constant in the form accepted for the data type state data type. If not specified, the state value starts out of NULL.

Sort operator

Use the drop-down list to select the sort operator (for a MIN- or MAX-like aggregate).


Operators

PostgreSQL supports left unary, right unary, and binary operators. Operators can be overloaded; that is, the same operator name can be used for different operators that have different numbers and types of operands. When a query is executed, the system determines the operator to call from the number and types of the provided operands.

Operator Editor allows you to define operator properties. It opens automatically when you create a new operator and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing operator
  • Browsing object dependencies
  • Editing operator description
  • Viewing DDL definition


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Operator Editor.

Operator Editor - Using Navigation bar

Object

iconDB select a database

select an operator for editing

General

iconCompile compile the operator (if it is being created/modified)

iconSaveDescription save the operator description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the operator

view the dependency tree for the operator

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the operator:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing operator

Use the Operator tab of Operator Editor to create/edit an operator and specify its definition.

Operator Editor - Editing operator definition

Name

Select a schema and enter the name of the operator to be defined. See below for allowable characters. Two operators in the same schema can have the same name if they operate on different data types. This is called overloading.

The operator name is a sequence of up to NAMEDATALEN-1 (63 by default) characters from the following list:

+ - * / < > = ~ ! @ # % ^ & | ` ?

There are a few restrictions on your choice of name:

  • -- and /* cannot appear anywhere in an operator name, since they will be taken as the start of a comment.
  • A multicharacter operator name cannot end in + or -, unless the name also contains at least one of these characters:

~ ! @ # % ^ & | ` ?

For example, @- is an allowed operator name, but *- is not. This restriction allows PostgreSQL to parse SQL-compliant commands without requiring spaces between tokens.

Function

The function used to implement this operator. Select it from the list of all database functions.

Left operand type

The type of the left-hand argument of the operator, if any. This option would be omitted for a left-unary operator.

Right operand type

The type of the right-hand argument of the operator, if any. This option would be omitted for a right-unary operator.

Commutator

Use the drop-down list to select the commutator of this operator.

Negator

Use the drop-down list to select the negator of this operator.

Restrict function

Use the drop-down list to select the restriction selectivity estimator function for this operator.

Join function

Use the drop-down list to select the join selectivity estimator function for this operator.

CheckBox Support hash joins

Check this option to indicate that this operator can support a hash join.

CheckBox Support merge joins

Check this option to indicate that this operator can support a merge join.

Left sort operator

If this operator can support a merge join, select the operator that sorts the left-hand data type of this operator.

Right sort operator

If this operator can support a merge join, select the operator that sorts the right-hand data type of this operator.

Less than operator

If this operator can support a merge join, select the less-than operator that compares the input data types of this operator.

Greater than operator

If this operator can support a merge join, select the greater-than operator that compares the input data types of this operator.


Collations

The collation allows to specify the sort order and character classification behavior of data per-column, or even per-operation. This alleviates the restriction that the LC_COLLATE and LC_CTYPE settings of a database cannot be changed after its creation.

Collation Editor allows you to define Collation properties. It opens automatically when you create a new Collation and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing Collation
  • Browsing object dependencies
  • Editing Collation description
  • Viewing DDL definition


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Operator Editor.

Collations- Using Navigation bar

Object

iconDB select a database

select an operator for editing

General

iconCompile compile the Collation (if it is being created/modified)

iconSaveDescription save the Collation description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the Collation

view the dependency tree for the Collation

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the Collation:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing collation

Use the Operator tab of Operator Editor to create/edit an operator and specify its definition.

Name

The name of the collation. The collation name can be schema-qualified. If it is not, the collation is defined in the current schema. The collation name must be unique within that schema.

Locale

This is a shortcut for setting LC_COLLATE and LC_CTYPE at once. If you specify this, you cannot specify either of those parameters.

Collation order

Use the specified operating system locale for the LC_COLLATE locale category. The locale must be applicable to the current database encoding.

Character classification

Use the specified operating system locale for the LC_CTYPE locale category. The locale must be applicable to the current database encoding.

Existing collation to copy from

The name of an existing collation to copy from. The new collation will have the same properties as the existing one, but it will be an independent object.


Statistics

The statistics creates a new extended statistics object to track data for the selected table, foreign table or materialized view.

Statistics Editor allows you to define Statistics properties. It opens automatically when you create a new Statistics and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing statistics
  • Browsing object dependencies
  • Editing description
  • Viewing DDL definition


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Statistics Editor.

Statistics- Using Navigation bar

Object

iconDB select a database

select a statistics for editing

General

iconCompile compile the Statistics (if it is being created/modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the Statistics

view the dependency tree for the Statistics

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the Statistics object:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Execute Script editor

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing statistics

Use the Statistics tab of Statistics Editor to create/edit a Statistics object and specify its definition.

Statistics Editor - Editing range type

Name

Set the name for the statistics.

Table

Select the table containing columns to calculate statistics.

Owner

Set the owner of the statistics object.

Columns

Select the columns to be covered by the computed statistics using the corresponding buttons. At least two column names or expressions must be specified, and their order is not significant.

Kind

Select statistics types to be calculated. If none is selecte, all supported statistics kinds are included in the statistics object.

CheckBox N-distinct

CheckBox Functional dependency

CheckBox Most-common values

Expression

Specify an expression to be covered by the computed statistics. This may be used to build univariate statistics on a single expression, or as part of a list of multiple column names and/or expressions to build multivariate statistics.


Non-schema Objects

Other types of objects are also stored in the database and can be created and manipulated with SQL, but are not contained in a schema:

  • Tablespaces
  • Languages
  • Local Scripts
  • Shared scripts

Use the DB Explorer tree to navigate within the database(s) and the objects.

See also:

Operations with database objects

New Object dialog

Duplicate Object Wizard

Schemas

Schema Objects


Event triggers

An Event Trigger fires whenever the event with which it is associated occurs in the database in which it is defined. Unlike regular triggers, which are attached to a single table and capture only DML events, event triggers are global to a particular database and are capable of capturing DDL events.

Event Trigger Editor allows you to define event trigger properties. It opens automatically when you create a new event trigger and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing event trigger
  • Browsing object dependencies
  • Editing event trigger description
  • Viewing DDL definition


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Event Trigger Editor.

Event Trrigger Editor - Using Navigation bar

Object

iconDB select a database

select an event trigger for editing

General

iconCompile compile the event trigger (if it is being created/modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the event trigger

view the dependency tree for the event trigger

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the tablespace:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing event trigger

Use the Trigger tab of Event Trigger Editor to create/edit an event trigger and specify its definition.

Name

Enter a name for the new event trigger, or modify the name of the event trigger being edited.

CheckBox Enabled

Enables/disables the event trigger immediately after it is created or modified.

Event Trrigger Editor - Editing event trigger

Event

Select the event on which the event trigger should be fired:

RadioButton Before DDL command

This option is equal to the ddl_command_start PosgreSQL event. This event occurs just before the execution of a CREATE, ALTER, or DROP command. No check whether the affected object exists or doesn't exist is performed before the event trigger fires.

RadioButton After SQL drop

This option is equal to the sql_drop PosgreSQL event. This event occurs just before the ddl_command_end event trigger for any operation that drops database objects.

RadioButton After DDL command

This option is equal to the ddl_command_end PosgreSQL event. This event occurs just after the execution of a CREATE, ALTER, or DROP command.

Command filter

You can filter the list of commands on which the event trigger should be fired. To select a command, you need to move it from the Available Commands list to the Selected Commands list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the commands from one list to another.

If you want the trigger to be fired on all commands of the event check the CheckBox Fire on all commands option.

In the lower area define the user-supplied function that is declared as taking no argument and returning type event_trigger. This function is executed when the trigger fires.

You can use already existing function and provide its name in the Function name field or create new one.


Tablespaces

A Tablespace allows superusers to define an alternative location on the file system where the data files containing database objects (such as tables and indexes) may reside.

Tablespace Editor allows you to define tablespace properties. It opens automatically when you create a new tablespace and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing tablespace
  • Browsing object dependencies
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Tablespace Editor.

Tablespace Editor - Using Navigation bar

Object

iconDB select a database

select a tablespace for editing

General

iconCompile compile the tablespace (if it is being created/modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the tablespace

view the dependency tree for the tablespace

iconMoveToTablespace move all objects from the current tablespace to another one (available for PostgreSQL 9.4)

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the tablespace:

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing tablespace

Use the Tablespace tab of Tablespace Editor to create/edit a tablespace and specify its definition.

Name

Enter a name for the new tablespace, or modify the name of the tablespace being edited. The name cannot begin with pg_, as such names are reserved for system tablespaces.

Owner

Use the drop-down list to select the name of the user who will own the tablespace. Only superusers may create tablespaces, but they can assign ownership of tablespaces to non-superusers.

Location

Specify the directory that will be used for the tablespace. The directory must be empty and must be owned by the PostgreSQL system user. The directory name must be specified as an absolute path string.

Tablespace Editor - Editing tablespace definition

The lower area displays the current Size of the tablespace being edited.


Languages

There are currently four procedural languages available in the standard PostgreSQL distribution: PL/pgSQL, PL/Tcl, PL/Perl, and PL/Python. Other languages can be defined by users.

Language Editor allows you to define language properties. It opens automatically when you create a new language and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing language
  • Browsing object dependencies
  • Editing object description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Language Editor.

Language Editor - Using Navigation bar

Object

iconDB select a database

select a language for editing

General

iconCompile compile the language (if it is being created)

iconSaveDescription save the language description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the language

view the dependency tree for the language

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the language:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing language

Name

The name of the new procedural language. The language name is case insensitive. The name must be unique among the languages in the database.

Language Editor - Editing language definition

CheckBox Trusted

This option specifies that the call handler for the language is safe, i.e. it does not offer an unprivileged user any functionality to bypass access restrictions. If this option is disabled, only users with the PostgreSQL superuser privilege can use this language to create new functions.

Handler function

Select the call handler function for this language from the drop-down list.

Call handler is the name of a previously registered function that will be called to execute the procedural language functions. The call handler for a procedural language must be written in a compiled language such as C with version 1 call convention and registered with PostgreSQL as a function taking no arguments and returning the language_handler type, a placeholder type that is simply used to identify the function as a call handler.

Validator function

Select the validation function for this language from the drop-down list.

Validator function is the name of a previously registered function that will be called when a new function in the language is created, to validate the new function.


Foreign Servers

A Foreign Server typically encapsulates connection information that a foreign-data wrapper uses to access an external data resource. Additional user-specific connection information may be specified by means of user mappings.

Foreign Server Editor allows you to define foreign server properties. It opens automatically when you create a new server and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing foreign server
  • User mapping
  • Browsing object dependencies
  • Editing object description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Foreign Server Editor.

Foreign Server Editor - Using Navigation bar

Object

iconDB select a database

select a foreign server for editing

General

iconCompile compile the foreign server (if it is being created)

iconSaveDescription save the foreign server description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the foreign server

view the dependency tree for the foreign server

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the language:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing foreign server

Name

The name of the new/existing foreign server. The server name must be unique within the database.

Foreign Server Editor - Editing foreign server

Foreign data wrapper

Use the drop-down list to select the Foreign data wrapper for the server being created.

Server type

Enter the optional server type.

Version

Enter the optional server version.

Options

Use the grid with Name and Value columns to specify the options for the server. The options typically define the connection details of the server, but the actual names and values are dependent on the server's foreign-data wrapper


User mapping

Use this tab to specify additional user-specific connection information.

Foreign Server Editor - User mapping

To add connection options for the Role use the New User Mapping item of the context menu.

To edit connection options for the Role use the Edit User Mapping item of the context menu.

Foreign Server Editor - User mapping - User Mapping

In the User Mapping dialog you can set the User and Password options for the selected Role. To manage these options use the New Option and Delete Option(s) context menu items.


Foreign Data Wrappers

All operations on a foreign table are handled through its Foreign Data Wrapper, which consists of a set of functions that the core server calls. The foreign data wrapper is responsible for fetching data from the remote data source and returning it to the PostgreSQL executor.

Foreign Data Wrapper Editor allows you to define foreign data wrapper properties. It opens automatically when you create a new foreign data wrapper and is available on editing an existing one.

  • Using Navigation bar and Toolbar
  • Creating/editing foreign data wrapper
  • Browsing object dependencies
  • Editing object description
  • Viewing DDL definition
  • Setting object permissions


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Foreign Data Wrapper Editor.

Foreign Data Wrapper Editor - Using Navigation bar

Object

iconDB select a database

select a foreign server for editing

General

iconCompile compile the foreign data wrapper (if it is being created)

iconSaveDescription save the foreign data wrapper description (if it has been modified)

iconRefresh refresh the content of the active tab

iconPrint print metadata of the foreign data wrapper

view the dependency tree for the foreign data wrapper

iconRestoreDefaultSize restore the default size and position of the editor window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with the language:

Description

iconSaveToFile save object description to file

iconCopyToClipboard copy description to clipboard

DDL

iconSaveToFile save DDL to file

open DDL in Query Data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Creating/editing foreign data wrapper

Name

The name of the new/existing foreign data wrapper. The foreign data wrapper name must be unique within the database.

Foreign Data Wrapper Editor - Editing foreign data wrapper

Handler function

This is the name of a previously registered function that will be called to retrieve the execution functions for foreign tables. The handler function must take no arguments, and its return type must be fdw_handler.

It is possible to create a foreign-data wrapper with no handler function by checking the No handler option.

Validator function

This is the name of a previously registered function that will be called to check the generic options given to the foreign data wrapper, as well as options for foreign servers, user mappings and foreign tables using the foreign-data wrapper. The validator function must take two arguments: one of type text[], which will contain the array of options as stored in the system catalogs, and one of type oid, which will be the OID of the system catalog containing the options.

If the No validator option is checked, then options will not be checked at creation time.

Options

Use the grid with Name and Value columns to specify the options for the server. The allowed option names and values are specific to each foreign data wrapper and are validated using the foreign-data wrapper's validator function. Option names must be unique.


Local Scripts

Local scripts are stored locally and can be easily accessed from the DB Explorer.

To create new local script right-click the appropriate branch in the DB Explorer tree and select the iconNewScript New Script item. You will be asked for the script name. When the name is assigned the script appears in the DB Explorer tree.

If a script is created in Execute Script editor and saved to the default folder, it will appear in the DB Explorer tree as local one.

Local Script - Setting script name

It is also possible to create subfolders in the Local scripts branch. Folders created there are created physically as subfolders to the folder assigned as default for local scripts in the DB Registration info | Directories.

To change directory where local scripts to be stored use the Select Directory item of the Local Scripts context menu, or use the respective field of the DB Registration info | Directories dialog. If specified folder already contained scripts, these scripts will be added to the DBExplorer tree.

Script is opened in the Execute Script where it can be edited or performed. You can also save local script as the shared one.

See also:

Execute Script Editor

Database Explorer

Shared Scripts

Database Registration Info


Shared scripts

Shared scripts are the scripts stored in the VCS repository. That makes scripts available for all the users working with the database having version control enabled.

Any script opened in the Script Editor can be saved as a shared script.

Note: Shared scripts are stored in the '%LocalRepositoryPath%\Trunk\Script' folder or its subfolders (where '%LocalRepositoryPath%' is a directory defined in the Database registration info | Change management | Working folder field).

Shared script is opened in the Execute Script Editor where you can edit or execute it.

See the topics below to get information about specific actions for shared scripts:

  • TFS
  • CVS
  • VSS
  • SVN

See also:

Execute Script

DB Explorer

Local Script

Database registration info

Change Management Settings

Change Management Tools


TFS

Actions you can perform under shared scripts in Team Foundation Server version control system:

iconAddToVC Add to version control

iconGetLatestVersion Get latest version

iconCheckIn Check in

iconCheckOut Check out

Adding script to version control

Enables version control for the selected script, script folder or whole shared script branch.

Operation is available only for scripts or folders that are not included in version control.

Getting latest version

Gets the selected script from server repository to either replace or to merge it with the local copy. You will be asked for operation confirmation. This should be used, if you need to discard all changes made to script locally and to start working with up-to-date script file. If the operation is applied to Shared Script branch of the DB Explorer (or any shared script folder) you will get information about all shared scripts added by other database users that work in the same VCS repository (or about script added to the folder).

Checking out

Enables edit mode for the script. This operation should be used when you need to add changes to script. It locks the script file so that nobody else can open it until you perform the Check In operation.

Checking in

Commits changes made to the script. You will be asked for transaction comments. After script is checked in, its latest version appears on server repository.

You can also browse shared script history. Use the Change management | iconChange Management - History History item of the context menu for this purpose.

You can identify current script state by its icon:

iconSharedScriptNotAdded Shared script is not added to version control;

iconSharedScriptUpdated Shared script is checked out and has been changed locally;

iconSharedScriptTFSAdded Shared script can't be edited until checked out;

iconSharedScriptCommitted Shared script is checked out and can be edited;

iconSharedScriptConflicted There is a conflict in this shared script.

Note: The most common situation for conflicts to occur is when you are trying to check in locally modified script, but there is a newer version of this script in server repository. Conflicts should be resolved manually by means of TFS. Shared scripts are stored in the '%LocalRepositoryPath%\Trunk\Script' folder (where '%LocalRepositoryPath%' is a directory defined in the Database registration info | Change management | Working folder field).

See also:

Shared scripts in CVS

Shared scripts in VSS

Shared scripts in SVN


CVS

Actions you can perform under shared scripts in Concurrent Versions System:

iconAddToVC Add to version control

iconUpdateFromVC Update from Version Control

iconCommitToVC Commit to Version Control

Adding script to version control

Enables version control for the selected script, script folder or whole shared script branch.

Operation is available only for scripts or folders that are not included in version control.

Updating script from Version Control

Merge two files: one from server repository and another from the local repository. Use this function when you need to work with the latest version of a file.

Committing changes to Version Control

Add latest changes made to shared script into server repository.

You can also browse shared script history. Use the Change management | iconChange Management - History History item of the context menu for this purpose.

You can identify current script state by its icon:

iconSharedScriptNotAdded Shared script is not added to version control;

iconSharedScriptUpdated Shared script is added to version control and contains uncommitted changes;

iconSharedScriptCommitted Shared script is added to version control and contains no local changes;

iconSharedScriptConflicted There is a conflict in this shared script.

Note: The most common situation for conflicts to occur is when you are trying to commit changes made to script, but there is a newer version of this script in server repository. Conflicts should be resolved manually by means of CVS. Shared scripts are stored in the '%LocalRepositoryPath%\Trunk\Script' folder (where '%LocalRepositoryPath%' is a directory defined in the Database registration info | Change management | Working folder field).

See also:

Shared scripts in TFS

Shared scripts in VSS

Shared scripts in SVN


VSS

Actions you can perform under shared scripts in Visual Source Safe version control system:

iconAddToVC Add to version control

iconGetLatestVersion Get latest version

iconCheckIn Check in

iconCheckOut Check out

Adding script to version control

Enables version control for the selected script, script folder or whole shared script branch.

Operation is available only for scripts or folders that are not included in version control.

Getting latest version

Gets the selected script from server repository to replace local copy. You will be asked for operation confirmation.

This should be used, if you need to discard all changes made to script locally and to start working with up-to-date script file. If the operation is applied to Shared Script branch of the DB Explorer (or any shared script folder) you will get information about shared scripts added by other database users that work in the same VCS repository (or about script added to the folder).

Checking out

Enables edit mode for the script. This operation should be used when you need to add changes to script.

Checking in

Commits changes made to the script. You will be asked for transaction comments. After script is checked in, its latest version appears on server repository.

You can also browse shared script history. Use the Change management | iconChange Management - History History item of the context menu for this purpose.

You can identify current script state by its icon:

iconSharedScriptNotAdded Shared script is not added to version control;

iconSharedScriptUpdated Shared script is checked out and has been changed locally;

iconSharedScriptTFSAdded Shared script can't be edited until checked out;

iconSharedScriptCommitted Shared script is checked out and can be edited;

iconSharedScriptConflicted There is a conflict in this shared script.

Note: The most common situation for conflicts to occur is when you are trying to check in locally modified script, but there is a newer version of this script in server repository. Conflicts should be resolved manually by means of VSS. Shared scripts are stored in the '%LocalRepositoryPath%\Trunk\Script' folder (where '%LocalRepositoryPath%' is a directory defined in the Database registration info | Change management | Working folder field).

See also:

Shared scripts in TFS

Shared scripts in CVS

Shared scripts in SVN


SVN

Actions you can perform under shared scripts in Subversion version control system:

iconAddToVC Add to version control

iconUpdateFromVC Update from Version Control

iconCommitToVC Commit to Version Control

Adding script to version control

Enables version control for the selected script, script folder or whole shared script branch.

Operation is available only for scripts or folders that are not included in version control.

Updating script from Version Control

Merge two files: one from server repository and another from the local repository. Use this function when you need to work with the latest version of a file.

Committing changes to Version Control

Add latest changes made to shared script into server repository.

You can also browse shared script history. Use the Change management | iconChange Management - History History item of the context menu for this purpose.

You can identify current script state by its icon:

iconSharedScriptNotAdded Shared script is not added to version control;

iconSharedScriptUpdated Shared script is added to version control and contains uncommitted changes;

iconSharedScriptCommitted Shared script is added to version control and contains no local changes;

iconSharedScriptConflicted There is a conflict in this shared script.

Note: The most common situation for conflicts to occur is when you are trying to commit changes made to script, but there is a newer version of this script in server repository. Conflicts should be resolved manually by means of SVN. Shared scripts are stored in the '%LocalRepositoryPath%\Trunk\Script' folder (where '%LocalRepositoryPath%' is a directory defined in the Database registration info | Change management | Working folder field).

See also:

Shared scripts in TFS

Shared scripts in CVS

Shared scripts in VSS


Change Management

Database Change Management

Change Management integrated into version control system (VCS) allows you to:

  • manage database related development processes;
  • remember database states;
  • get a script with differences between two database states;
  • test generated scripts on a test database;
  • rollback database to any of its previous versions;
  • browse history of database and/or object changes;
  • store any SQL scripts in version control system repository of a database.

Change management makes the process of deploying changes and updates from development to testing and production environments easier and more controllable.

Supported VCS: Concurrent Versions System (CVS), Subversion (SVN), Visual SourceSafe (VSS), Team Foundation Server (TFS).

This tool can be useful not only for development teams, but also for single developers, who are in need of a mean for managing database versions, or whose databases have complex business logic in procedures, triggers etc.

Change management tools can be accessed through the respective section of database context menu or Tools section of the main menu.

Change management tools - menu

To enable Change Management for a database you need to define connection settings for the VCS and create database repository. Open the Database Registration Info dialog at the Change management tab and launch the Version Control Repository Management Wizard for this purpose.

What VCS stores

Database VCS repository stores:

  1. All database objects in XML files. All the object properties that affect object definition are recorded into these files
  2. SQL scripts with all changes in the database
  3. Database backups created with each label
  4. User can add custom files to VCS (so-called shared scripts)

SQL manager automatically records each changing of a database object (made in object editor, or by SQL script) to the respective file and to database history and then commits these changes to VCS.

If database was changed in other program, not in SQL Manager, Check Version Control Repository Wizard provides resolving of differences in database and its description in the VCS repository. It is strongly recommended to launch Check Repository Wizard to reveal and remove such differences.

Repository stores metadata only, not data.

Branches, labels, tags

Change Management tool allows you to create database branches. Database branch is a copy of original DB and corresponding branch in the database repository. Database that has been originally added to VCS is a trunk branch of the repository. On branch creation any PostgreSQL server can be specified as destination for created branch database if its version coincides with the version of original server.

Database tags and labels can be created as well. Database tag is a mark for all database files in VCS repository. Using tags is recommended for marking definite database state or version. This provides possibility to get differential script to this state.

Database label is a database tag plus database backup copy. It enables restore of the database to the labeled state. Label is always created when creating a branch. In this case label gets the name of the branch with “_AutoLabel” ending. During initial creation of database repository, the label named “Trunk_AugoLabel” is created automatically.

Get Change script

One of the key features of Change Management is the possibility to get script of database changes from tag/time point/current database state to another tag/date/current database state. Script can be generated in two ways: differential or step-by-step.

Differential script is a result of comparing of two database states. Step-by-step script is an aggregate of all database changes occurred in a period. Step-by-step script can generated only for two contiguous database states and only in forward direction. For example, such script can be generated for two database states within a single branch. Step-by-step script contains all SQL statements that have been performed from start time point to destination one. It means that all intermediate changes of an object will be included to script. Instead of step-by-step script, differential script contains only sum of these changes. Step-by-step scripts, as opposed to differential ones, can contain DML statements in addition to DDL statements. Using of step-by-step scripts is more secure if all changes to database have been made in SQL Manager only.

Change Management tools

Tools available:

  1. Check Version Control Repository Wizard. Defines whether object description in repository matches object properties in database. If differences persist, wizard corrects repository in order to eliminate them and adds the script with missing statements to DB history.
  2. Create Tag Wizard. Provides tag, label or branch creation. Also allows restore of database from an existing label. Such database will not be included in change management, and can be used, for example, for testing scripts.
  3. Get Change Script Wizard. Enables getting script with changes from tag/date/current database state to tag/date/current database state.
  4. Release New Version of Database Wizard. Automates intermediate processes that are required when releasing new version of database. Allows to get script with changes between previous version of database and current one and to test this script on previous database version. The wizard includes the following operations:
    1. VCS repository is checked to ensure that description exactly matches current database state (same as Check Version Control Repository Wizard performs).
    2. Current database state is marked in the VCS repository with tag or label. This provides ability to get change script with possible additional changes.
    3. Script with changes between previous version of database and current database state is generated.
    4. Test database is created from for example an existing label. Generated scripts are tested on this database. After script is executed, test database is compared with current database state to ensure that there no differences between them.
  5. Database History. Shows all changes of database in specified branch. History is a list of scripts performed on database.

Object History. Shows all changes of a DB object similar to file history in VCS.

Connect to VCS

To access change management tools:

Select the Tools | Change Management item of the main menu

or

Select the Change Management item from the database or host context menus.

For a single database object only object history can be browsed.

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Query Management Tools

Data Management

Import/Export Tools

Database Tools

Services

Options

How To...


Create branch/label/tag wizard

This wizard allows you to create tag, label or branch.

Tag is a special mark that defines certain database state. (It is a marks for all files of the database repository in the specified branch)

Label is a special mark that defines certain database state. With the label a backup copy of the database is created. Label provides database state for creating database branch/copy.

Branch is an independent direction of database development. It is a database copy which can be modified with no effect on the original database (database in head branch). Objects in different branches are identical before branching point and divergent after it. Label is always created with branch. (This branch is for all files of DB repository in VCS plus copy of the original database)

To launch the wizard use the Change Management | iconChange Management - Create branch-Label-Tag Create Branch/Label/Tag item of the host or database context menu. Alternatively you can use the Tools | Change Management | iconChange Management - Create branch-Label-Tag Create Branch/Label/Tag item of the main menu.

  • Selecting source database
  • Selecting operation
  • Setting created object options
  • Specifying connection settings
  • Performing operation

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Check repository wizard

Get change script wizard

Release new version of database

History


Selecting source database

In this step you need to select the database to create a tag for. Proceeding to the next step is possible only when VCS is enabled for the selected database.

Create Branch-Label-Tag - Select source database

Use the drop-down list to select Source database.

Click the Next button to proceed to the Selecting operation step of the wizard.


Selecting operation

In this step you need to select type of the operation to be performed.

Create Branch-Label-Tag - Select operation

RadioButton Create branch

Use this option to create a branch.

If needed you can create branch CheckBox From existing label. Enable the appropriate option and select a label from the drop-down list for the purpose.

RadioButton Create label

Use this option to create a label.

RadioButton Create tag

Select the option to create a tag.

RadioButton Create database from label

This option allows you to create a database from label. Select a label from the corresponding drop-down list.

Branch / Label / Tag name

Defines the name of the created object.

CheckBox Move tag/label if it already exists

Enable the option to move the existing object with the new one if their names coincide.

Click the Next button to proceed to the Setting created object options.

If a tag is created then clicking the Next button will move you to the last step.


Setting created object options

This step appears only when creating label. Use this step to define label parameters.

Create Branch-Label-Tag - Create branch

Backup storage location

Use this section to define whether to store database backup in RadioButton Version Control Repository or RadioButton Separately.

CheckBox Backup metadata only

Disable the option if you need full database backup to be created with the label.

Click the Next button to proceed to the Specifying connection settings step.


Specifying connection settings

This step appears when creating branch or database from label (action specified at the Selecting operation step). Use this step to define settings for new database.

Create Branch-Label-Tag - Specify database destination

Use the Host drop-down list to define server. This list contains all registered hosts.

Use the corresponding field to specify Port for connection.

Define User name and Password for server authorization.

Database name must be specified within the appropriate field.

Click the Next button to proceed to the final step.


Performing operation

This step of the wizard is intended to inform you that all necessary options have been set, and you can run branch/label/tag creating process.

The log area allows you to view the log of operations and errors (if any).

Create Branch-Label-Tag - Run

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed.

Click the Run button to create branch/label/tag.


Check repository wizard

Check repository wizard reveals differences (if any) between database state and its description in the VCS repository and eliminates ones if any. This wizard should be used when any changes have been made to database without synchronization to the corresponding repository e.g. changes made when VCS was disabled for the database.

To launch the wizard use the Change management | Check repository... item of database context menu (or any database object context menu), or use the Tools | Change management | Check repository... main menu item.

  • Selecting database
  • Selecting object types
  • Checking repository
  • Specifying action for each difference
  • Selecting objects to remove from the repository
  • Checking and correcting script
  • Adding comments
  • Performing operation

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Create tag wizard

Get change script

Release new version of database

History


Selecting database

In this step you should select a database to check version control repository. Proceeding to the next step is allowed only if VCS is enabled for the selected database.

Check Repository - Select Database

Use the Database to check drop-down list for the purpose.

Click the Next button to proceed to the Selecting object types step of the wizard.


Selecting object types

In this step you need to select object types for check repository operation.

Check Repository - Select objects types

RadioButton Check the whole database

Selects all database objects for check repository operation.

RadioButton Check selected object types only

This option enables selecting object types manually. This option enables selecting object types manually. Selecting object types manually can increase speed of operation performance, but it also can make it less secure.

Click the Next button to proceed to the Checking repository step of the wizard.


Checking repository

This step informs you that all necessary settings are defined and version control repository can be checked.

The log area allows you to view the log of operations and errors (if any). Errors state for differences between database objects and their description in the repository.

Check Repository - Check Repository

If differences are present, then the repository should be changed in order to correspond with current state of the database.

If no differences have been found, proceeding with the next step of the wizard is unavailable.

You can repeat repository checking clicking the Check Again button.

Click the Next button to proceed to the Specifying action for each difference step of the wizard.


Specifying action for each difference

In this step you can view objects that have been changed and whose changes are not reflected in the repository.

Use the Action column to define action for the selected object.

Save

This action is available only for objects that exist in database and are described in VCS repository but whose properties are not up to date. Use the option to add changes to the object description.

Create New/Replace Existing

This actions appear for objects that exist in database but have no description in the database VCS repository. Use the Create New option to add new description, or the Replace Existing to substitute the existing description. If the Replace Existing option is selected, the Replacement should be defined. Note that the Replacement field contains the list of similar objects that are described in the repository but are absent from the database.

Check Repository - Specify action

Click the Next button to proceed to the Selecting objects to remove from the repository step.


Selecting objects to remove from the repository

Use this step to mark objects to remove its description from the repository.

Table contains only objects whose descriptions exist in VCS repository but are absent from the database.

Check Repository - Select missed objects

Click the Next button to proceed to the Checking and correcting script step.


Checking and correcting script

This step allows you to view and correct script with changes selected at the previous steps.

In this editor you can use all the features available in Query Data: syntax highlight, code completion etc.

Note: This script will not be executed. It will be added to the database history in the version control repository. If database history already contains commands that caused such changes in the database, remove corresponding commands from the script.

Check Repository - Check and correct script

Click the Next button to proceed to the Adding comments step of the wizard.


Adding comments

Use this step to bind commentaries to the changes that will be made to the version control repository.

Changes that will be applied to the repository you can find in the Specifying action for each difference and Selecting objects to remove from the repository steps of the wizard.

Check Repository - Specify comments

Click the Next button to proceed to the final step.


Performing operation

This step informs you that all necessary settings are defined and changes can be applied.

The log area allows you to view the log of operations and errors (if any).

Check Repository - Run

Click the Run button to apply changes defined at the previous steps.

To close the wizard after successful completion of the operation use the corresponding option.


Get change script wizard

Get change script wizard generates script that reflects differences between two database states. This script can be used to bring database to the required state. Any database state existing in its version control history can be taken as start or end point.

To launch the wizard use the Change management | iconChange Management - Get Change script Get change script... item of database context menu (or any database object context menu), or use the Tools | Change management | iconChange Management - Get Change script Get change script... main menu item.

  • Selecting source database
  • Selecting script generation method
  • Specifying start and end points for the script
  • Specifying comments
  • Specifying script destination
  • Performing operation

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Create branch/label/tag wizard

Check repository wizard

Release new version of database

History


Selecting source database

Use this step to select source database to get change script. Proceeding to the next step is allowed only if VCS is enabled for the selected database.

Get Change Script - Select Database

Use the Source database drop-down list for the purpose.

Click the Next button to proceed to the Selecting script generation method step.


Selecting script generation method

This step allows you to select script generation method.

Get Change Script - Select script generation method

RadioButton Generate step-by-step script

Use this method to generate script that reflects consecutive changes made to database during the period defined at the next step.

Note: This script can't be used to rollback to the initial state of the database (start point).

RadioButton Generate differential script

Using this method the program generates script reflecting difference between two database states.

Note: Script generated using this method never contains intermediate changes of an object.

Click the Next button to proceed to the Specifying start and end points for the script step of the wizard.


Specifying start and end points for the script

This step allows you to define the period. Generated script will consider changes made in this period.

Get Change Script - Specify start and end points

Script start point

First select start point type: RadioButton Tag or RadioButton Date. Then either select tag from the drop-down list, or specify date. RadioButton Last revision of branch can be selected as start point only when getting differential script.

Script end point

First select end point type: RadioButton Last revision of branch (current database state), RadioButton Tag or RadioButton Date. Then either select tag from the drop-down list, or specify date.

Note: When the Step-by-step method of script generation is selected the Tag list will contain all tags/labels from current and parent branches. Tags/labels from parent branches appear in the list only if these branches heads are located in VCS tree structure higher than last revision the of branch.

Script end point

First select end point type: RadioButton Last revision of branch (current database state), RadioButton Tag or RadioButton Date. Then either select tag from the drop-down list, or specify date.

Note: If the step-by-step mode is selected in the previous step, start point must be earlier then end point.

Click the Next button to proceed to the Specifying comments step of the wizard.


Specifying comments

This step allows you to select comments to be added to each statement script of the script. When getting differential script this step is unavailable.

Get Change Script - Specify comments

Check the needed options to add corresponding comment to each script statement.

To disable comments uncheck the CheckBox Add description option.

Click the Next button to proceed to the Defining script destination step of the wizard.


Specifying script destination

In this step you need to set script destination.

Get Change Script - Specify script destination

RadioButton Automatically load to Script Editor

With this option enabled the generated script will be opened in Script Editor where you can execute it at once.

RadioButton Save to file

Use this option to save script to a file for future use. File name and its location is defined in the File name field.

Regardless of the script destination selected you need to define Script character set.

Click the Next button to proceed to the final step of the wizard.


Performing operation

This step informs you that all necessary settings are defined and change script can be generated.

The log area allows you to view the log of operations and errors (if any).

Get Change Script - Run

Click the Run button to generate change script.

CheckBox Load script to Script Editor

Enable the option to open the result script within the Execute Script Editor.

To close the wizard after successful completion of the operation use the corresponding option.


Release new version of database

Release new database wizard provides automatic performing of all necessary operations that required for new database release.

It allows you to get script with database changes from previous state to current one and to test it on the previous database state.

The wizard consists of the following operations:

1. VCS repository is checked to define whether it contains the exact description of current database state (similar to the Check repository wizard).

2. Actual position of the database in VCS repository is labeled/tagged. This provides possibility to get script with the additional changes made after this point if such changes appear.

3. The script containing changes from previous database state to current is generated.

4. Test database is created from previous state label/tag. Change script is tested on this database. Then the result database is compared to current version.

To launch this wizard use the Change Management | Release New Version of Database item of the host or database context menu.

You can also use the Tools | Change management | Release New Version of Database item of the main menu.

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Create branch/label/tag wizard

Check repository wizard

Get change script wizard

History


Selecting versions source

This step allows you to select the database to release and it's previous version.

Release New Version - Select new and previous versions source

Select the new version database from the appropriate drop-down list.

Previous version

This section defines previous version parameters.

RadioButton In label

Use this mode to get previous database version from an existing label.

RadioButton In database

This mode allows you to get previous database version from a database.

Select the needed object from the list.

CheckBox Only test existing script

This option defines whether to generate new change script. Enable the option to proceed to the step where you can select an existing script file and test it.

Click the Next button to proceed to the Checking repository step.

If the CheckBox Only test existing script is selected, then you will proceed to the Checking repository step.


Checking repository

Click the Run button to check repository of the selected database.

The log area allows you to view the log of operations and errors (if any). Errors state for differences between database objects and their description in the repository.

Release New Version - Check the repository

If errors were found, then the repository should be changed in order to correspond with current state of the database.

You can repeat repository checking clicking the Check Again button.

CheckBox Skip error correction

Enable the option to skip repository errors correction, but it is not recommended.

Click the Next button to proceed to the next step.

If no errors found you will proceed with the Creating label/tag step. Otherwise the Creating label/tag step will be the next.


Specifying actions for problems to resolve

In this step you can view objects that have been changed and whose changes are not reflected in the repository.

Use the Action column to define action for the selected object.

Save

This action is available only for objects that exist in database and are described in VCS repository but whose description is not up to date. Use the option to add changes to the object description.

Create New/Replace Existing

This actions appear for objects that exist in database but have no description in the database VCS repository. Use the Create New option to add new description, or the Replace Existing to substitute the existing description. If the Replace Existing option is selected, the Replacement should be defined. Note that the Replacement field contains the list of similar objects that are described in the repository but are absent from the database.

Release New Version - Specify appropriate action

Click the Next button to proceed to the Selecting objects to delete from repository step.


Selecting objects to delete from repository

Use this step to mark objects to remove its description from the repository.

Table contains only objects whose descriptions exist in VCS repository but are absent from the database.

Release New Version - Select missed objects

Click the Next button to proceed to the Checking and correcting script step.


Checking and correcting script

This step allows you to view and correct script with changes selected at the previous steps.

In this editor you can use all the features available in Query Data: syntax highlight, code completion etc.

Note: This script will not be executed. It will be added to the database history in the version control repository. If database history already contains commands that caused such changes in the database, remove corresponding commands from the script.

Release New Version - Check and correct script

Click the Next button to proceed to the Specifying comments step.


Specifying comments

Use this step to bind commentaries to the changes that will be made to the version control repository.

Changes that will be applied to the repository you can find in the Specifying action for each difference and Selecting objects to remove from the repository steps of the wizard.

Release New Version - Specify comment

Click the Next button to proceed to the Performing repository correction step.


Performing repository correction

This step informs you that all necessary settings are defined and changes can be applied.

The log area allows you to view the log of operations and errors (if any).

Release New Version - Perform correction

Click the Next button to return to the Checking repository step. Repository re-checking is necessary to make sure that no errors persist.


Creating label/tag

Creating of label or tag is necessary for marking current database state.

Use the RadioButton Create label option if you are not planning to make changes to the released database version.

Use the RadioButton Create tag option if not all the changes were applied and it is planned to get change script with further changes.

Release New Version - Create a label or a tag

RadioButton Don't create

Use this option to skip label/tag creation.

Label/Tag name

Specifies name for created tag or label.

CheckBox Move label/tag if it already exists

Enable the option to move the existing object with the new one if their names coincide.

Depending on the option selected the you will proceed to different steps:

For Create label selected - the next step will be Specifying label options;

For Create tag selected - the next step will be Performing label creation;

For Don't create selected - the next step will be Generating change script.


Specifying label options

This step appears only when label is created. Use this step to define label parameters.

Release New Version - Specify created label options

Backup storage location

RadioButton Version Control Repository

Database backup copy will be stored in the VCS repository folder.

RadioButton Separately

Database backup copy will be stored in the folder specified below.

CheckBox Backup metadata only

Disable the option if you need full database backup to be created with the label.

Click the Next button to proceed to the Performing label creation step.


Performing label creation

This step is intended to inform you that all necessary settings have been defined and you can perform tag or label creation.

The log area allows you to view the log of operations and errors (if any).

Release New Version - Perform label creation

Click the Run button to create label/tag.

After the operation is successfully finished, Next button appears instead of Run. Click the button to proceed to the Generating change script step.


Generating change script

Use this step to define change script creation parameters.

Release New Version - Generate change script

RadioButton Generate new script file

For the new script you need to define its location and file name. Use the corresponding field for this purpose.

You also need to select File charset from the drop-down list.

CheckBox Add script to version control repository

Enable the option to add created script to the database VCS repository. The option can be enabled only if specified script file location is the same as the local repository folder directory where shared scripts are stored.

RadioButton Append latest changes to existing script file

Use this mode if change script has been already generated by the Release New Version of Database Wizard, but then changes were added to the released database. It is supposed that label have been created after previous script generation.

Script file name

Select existing script file within this field. Use the btnSaveAs Save As button to open dialog window to ease file selecting.

Get latest changes from

Select tag or label from this drop-down list. Only latest changes will be added to the script selected in the Script file name field. In this case the Previous version selected at the first step will be used only for providing information concerned test database, but not for script generation.

If the RadioButton Generate new script file mode is selected, the next step will be Selecting method of script generation.

Otherwise the wizard will proceed with the Specifying test database location step.


Selecting method of script generation

Use this step to select generated script type.

Release New Version - Set script generation method

RadioButton Generate differential script (by comparing states)

Using this method the program generates script reflecting difference between two database states.

Note: Script generated using this method never contains intermediate changes of an object.

RadioButton Generate step-by-step script (all changes from the change history)

Use this method to generate script that reflects consecutive changes made to database. Script will contain all statements from VCS history between its previous and actual states.

For differential script generation the next step will be the Performing script generation; for step-by-step - Specifying comments.


Specifying comments

This step allows you to select comments to be added to each statement script of the script. When getting differential script this step is unavailable.

Release New Version - Perform script generation

Check the needed options to add corresponding comment to each script statement.

To disable comments uncheck the CheckBox Add description option.

Click the Next button to proceed to the Performing script generation step.


Performing script generation

This step informs you that all necessary settings are defined and change script can be generated.

The log area allows you to view the log of operations and errors (if any).

Release New Version - Generating and Testing Script

Once the operation is performed, the Next button appears. Click the button to proceed to the Specifying test database location.


Specifying script to test

This step appears if the CheckBox Only test existing script option was enabled at the first step.

Use this step to define name of script file to be checked.

Release New Version - Specify script file to test

Script file name

Use the field to define file name and location.

If program can't define file encoding, then clicking the Next button opens the Script Conversion dialog where script encoding can be defined manually.

Release New Version - Specify script file to test - Script Conversion

When encoding is defined click OK to proceed to the Selecting the way of getting test database step.


Selecting the way of getting test database

In this step you need to define the way of getting test database.

Release New Version - Specify test database location

RadioButton Restore from the previous version label or RadioButton Backup/restore the previous version database

Use this mode to get test database by restoring from label backup or from previous version of database respectively.

Note: Option name depends on the previous version source selected in the first step.

RadioButton Restore an existing backup copy

Select this mode to get test database by restoring from a backup copy.

Backup copy location

Define backup copy location within this field. Use the ExplorerButton Open button locate backup file using standard dialog.

RadioButton Use existing database

Use an existing database as a test one. You can define connection properties in the next step.

Click the Next button to proceed to the Specifying test database location step.


Specifying test database location

Use this step to define test database connection parameters.

Release New Version - Perform test database creation

Host

Use the drop down list to select one of the registered hosts where database is located.

Specify User name and Password to be used for connection.

Specify the Database name to be created/registered.

CheckBox Register database if not registered

Enable the option to register the database if it is not registered yet.

If the RadioButton Use existing database option was selected in the previous step, the wizard will proceed with the Confirming checking test database step. Otherwise the next step will be Performing test database creation.


Performing test database creation

This step informs you that all necessary settings are defined and test database can be created.

Click the Run button to perform the operation.

The log area allows you to view the log of operations and errors (if any).

Release New Version - Check the created test database

After the operation is completed the Database Registration Info dialog appears. It allows you to check and modify database registration information.

Run button also changes to Next. Click the button to proceed to the Confirming checking test database step.


Confirming checking test database

Use this step to define whether to CheckBox Compare the test database with the original previous version database.

During this process complete metadata of two databases is compared.

Release New Version - Perform comparing

If you enable the option, the wizard will proceed with the Perform comparison of test database with new version of database. Otherwise, the next step will be Executing change script on test database.


Performing comparison of test database with the previous version of database

In this step test database will be compared with the previous version of the database.

Release New Version - Bring the test database to the previous state

To start the process click the Run button.

The log area allows you to view the log of operations and errors (if any).

Click the Next button to proceed to the Executing change script on test database step.


Bringing test database to previous version of database state

This step appears if comparison of test database and previous version of database revealed differences.

Release New Version - Execute the change script on the test database

CheckBox Ignore the difference

Enable the option to skip re-comparing test database and previous version of database. It is recommended to leave the option disabled.

The Open Script button launches the Execute Script with change script loaded. You can execute this script on test database to bring it to correspondence with previous version of database.

Correct the script if needed, then execute it on test database and return to the wizard by clicking the Save&Return to Wizard button.

Release New Version - Execute the change script on the test database_2

If the Ignore the difference option is enabled, the wizard will take you to the Executing change script on test database step.

Otherwise you will return to the Performing comparison of test database with the previous version of database step.


Executing change script on test database

In this step the corrections can be added to the generated change script. Moreover this script can be executed on test database.

Release New Version - Execute the change script on the test database_1

Open Script

The Open Script button launches the Execute Script with change script loaded. You can execute this script on test database to bring it to correspondence with previous version of database.

Correct the script if needed, then execute it on test database and return to the wizard by clicking the Save&Return to Wizard button.

Release New Version - Execute the change script on the test database_2

If the script is not executed on test database, the wizard will take you back to the Perform comparison of test database with the previous version of database step. Otherwise, you will proceed to the Specify how to test the generated additional change script step.


Performing comparison of test database with the new version of database

Use this step to perform comparison of test database with new version of database.

Release New Version - test the generated change script

To launch the process click the Run button.

The log area allows you to view the log of operations and errors (if any).

Click the Next button to proceed to the final step. If the operation completed unsuccessfully, you will be taken to the Specify action for the test database step.


Specify action that will be performed with the test

SQL Manager for PostgreSQL
  • Index
  • « Prev
  • Next »

Specify action for the test database

This step appears when additional script was generated because of differences found between test and target databases.

Release New Version - action that will be performed with the test

RadioButton Append the additional script to the original and test the entire script

Select this option to add update change script and test it on new test database.

Use the corresponding options to CheckBox Drop the test database and/or CheckBox Unregister the test database. These actions will be applied to the previously created test database.

RadioButton Test only the additional script on the current test database

Use this mode to test only additional statements of differential script. Statements will be tested on the previously created test database. The script file will be opened in Execute Script Editor on clicking the Next button.

Click the Open Script button to view the additional script in the Execute Script Editor.

If the RadioButton Append the additional script to the original and test the entire script option is selected, the wizard will take you back to the Selecting the way of getting test database step. Otherwise, you will proceed to the Performing comparison of test database with the new version of database step of the wizard.


Finishing the operation

This is the final step of the wizard. Script has been created and tested successfully. No differences have been found between test database and new version of database.

If needed, you can drop and unregister test database using respective options.

Release New Version - Finishing the operation

Click Run to drop and/or unregister test database, or Close to exit the wizard.


History

With this tool you can view all the changes made to database/object.

To open database/object history use the Change management | iconChange Management - History History item of database/object context menu, or select the Tools | Change management | iconChange Management - History History item of main menu.

  • Database history
  • Object history
  • Comparing object versions

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Create tag wizard

Check repository wizard

Get change script


History of database changes

Use the navigation bar to select Database. Define the Period within the corresponding section. Changes made in this period will be displayed in the working area.

Change Management - Version Control History

At the top of the window you can find a table that displays information about changes made in the specified period. It displays transaction ID, Date when transaction was made, name of the User who made changes and Comment to a transaction if any.

Note: You can customize grouping and filtering within this table.

In the bottom part of the window you can view SQL statement of the selected action.

See also:

Object history

Comparing object versions


Object history

You can browse change history of any object.

To open object history use the Change management | iconChange Management - History History item of object context menu.

Change Management - Object History

History of object changes is displayed as table. In this table you can find the following information: database Revision and Date when object was changed. The Author of changes made to object is also displayed.

Comment part of the window displays comments to the selected object modification.

The navigation bar of this window allows you to iconDB select database, to iconRefresh refresh data and to iconSelectObject select object.

See also:

History of database changes

Comparing object versions


Comparing object versions

You can view differences between two object versions.

Change Management - Object History - Revisions

Select two object revisions you need to compare. Right-click any of the objects to call the context menu and select the Compare Properties or Compare Scripts item to view differences as table of properties or as object script respectively.

The window displaying progress of the operation will appear. Close it to view the results of the operation.

Change Management - Object History - Comparing progress

Check the CheckBox Close after finish flag if you need the results window appear once the operation is finished.

Viewing properties comparison results:

Change Management - Object History - Comapring Properties

Window contains table where you can see all object properties and its value in compared revisions. Properties with different values are highlighted with grey.

Viewing script comparison results:

Change Management - Object History - Comapring Scripts

Window contains DDL of objects revisions. Extra lines in an early revision script are red, in latter revision - grey. Lines for pasting absent lines are yellow and different lines are blue.

Use the toolbar buttons to move cursor to btnMoveItemUp Previous difference or to btnMoveItemDown Next one, to btnFindText Find word or statement or to btnSearchAgain Find next one.

See also:

History of database changes

Object history


Query Management Tools

When using SQL Manager for PostgreSQL, you are provided with two basic tools you may need to manage your SQL queries: Query Data for editing SQL query text directly and Design Query for building queries visually. Find the list of common SQL query management operations below.

Creating New Queries

In order to create a new query in Query Data:

  • select the Tools | Query Data main menu item or use the corresponding btnNewSQLEditor toolbar button;
  • click the Add new query item of the Navigation bar;
  • edit the query text within the Query tab of Query Data.

In order to create a new query in Design Query:

  • select the Tools | Design Query main menu item or use the corresponding btnNewQueryBuilder toolbar button;
  • build the query visually within the Builder tab of Query Designer.

Editing Queries

In order to open a query in Query Data:

  • select the Tools | Query Data main menu item or use the corresponding btnShowSQLEditor toolbar button;
  • use the numbered tabs at the bottom of the editor window to switch between previously edited queries. The last edited query is displayed automatically on opening the editor;
  • edit the query text within the Query tab of Query Data.

In order to open a query in Design Query:

  • select the Tools | Design Query main menu item or use the corresponding btnShowQueryBuilder toolbar button;
  • the last edited query is displayed automatically on opening Design Query;
  • to load a previously saved diagram, click the Load diagram item of the Navigation bar;
  • to load a query from an *.sql file, open the Query tab and click the Load SQL button of the Navigation bar;
  • edit the query visually within the Builder and/or the Query tabs of Design Query.

In order to load a query from an *.sql file:

  • select the Tools | Query Data main menu item or use the corresponding btnNewSQLEditor toolbar button;
  • click the Load from file item of the Navigation bar;
  • browse for the query file using the Open SQL File dialog;
  • edit the query text within the Query tab of Query Data.

Executing Queries

  • create a new query or open an existing one;
  • click the btnExecuteQuery Execute item of the Navigation bar or use the F9 hot-key to execute the query;
  • view/edit the returned data within the Results tab of Query Data.

Saving Queries

  • create a new query or open an existing one;
  • click the Save to file Navigation bar item (in Query Data) or the Save SQL Navigation bar item (in Design Query), or use the Ctrl+S shortcut to save the query using the Save as... dialog;
  • click the Save diagram Navigation bar item in Design Query to save the designed diagram;

or

  • use the Save all Navigation bar item in Query Data if you need to save all the queries to one file.

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Data Management

Import/Export Tools

Database Tools

Services

Options

How To...


Query Data

Query Data is the basic tool of SQL Manager for PostgreSQL for creating and executing queries. The tool allows you to create and edit the SQL text of a query, prepare and execute queries and view the results of query execution.

To open Query Data select the Tools | Query Data main menu items or use the corresponding btnNewSQLEditor / btnShowSQLEditor toolbar buttons. You can also use the Shift+F12 / F12 shortcuts for the same purpose.

  • Using Navigation bar and Toolbar
  • Working with Query Data area
  • Using the context menu
  • Viewing query plan
  • Using object links
  • Executing queries and viewing results
  • Viewing query logs
  • Favorites editor

See also:

Design Query

Query parameters

Execute Script editor

Editor Options


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Query Data.

SQL Editor - Using Navigation bar

Database

iconDB select a database for the query

General

iconExecute execute the current query

view estimated query execution plan

run Design Query to design the query as a diagram

switch the results representation mode: on Edit tab or on separate tab

iconOptions configure Query Data editor at Environment Options dialog

iconRestoreDefaultSize restore the default size and position of the editor window

iconDisableAllCodeFeatures disable/enable all code features

Queries

add a new query (note that the current query text will not be lost)

rename the current query

remove the query

remove all queries from the editor

edit the query text using Favorites editor and add the query to the Favorite Queries list

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with queries:

Edit

iconFindText activate the Find Text dialog

iconLoadFromFile load a query from an *.sql file using the Open SQL File dialog

iconSaveToFile save the query to an *.sql file

iconSaveToFileAs save the query to an *.sql file using the Save as... dialog

iconSaveAll save all queries to an *.sql file

Logs

iconFindText activate the Find Text dialog

iconSaveToFile save the query log to a file

clear logs

Data Management

iconCommit commit transaction

iconRollback rollback transaction

Note: These actions are available if the CheckBox Use transactions in object editors, Query Data and Design Query option is checked in the Database Registration Info | Data options dialog.

export the returned dataset using Export Data Wizard

export the returned dataset as SQL Script using the Export as SQL Script wizard

import data

NB: You can enable\disable Toolbars and Navigation bars at Environment options.

See also:

Working with editor area

Viewing query plan

Executing queries

Viewing query logs

Favorites editor


Working with Query Data area

The Editor area of Query Data editor is available within the Query tab and is provided for working with SQL queries in text mode.

For your convenience the syntax highlight, code completion and a number of other features for efficient SQL editing are implemented:

  • using object links allowing you to open the object in the associated editor;
  • ability to display line numbers;
  • code folding for statements and clauses;
  • customizable margins and gutters;
  • formatting code for better representation

and more.

If necessary, you can enable/disable or customize most of Query Data editor features using the Editor Options dialog.

The example of code completion is illustrated in the picture below. You can set the delay within the Quick code section of the Editor Options dialog or activate the completion list manually by pressing the Ctrl+Space shortcut.

SQL Editor - Working with SQL Editor area

For your convenience the possibility to use macros is implemented.

To start recording a macro, click the btnRecordMacro Record button available in the status bar area, or use the Shift+Ctrl+R shortcut.

To stop recording, click the btnStopRecordMacro Stop button, or use the Shift+Ctrl+R shortcut.

To call the recorded macro, use the btnPlayMacro Play button, or use the Shift+Ctrl+P shortcut.

Hint: To use a keyboard template, type the template name and press the Ctrl+J shortcut: the text associated with the template will be inserted automatically.

If necessary, you can print the SQL text of your query using the corresponding item of the context menu.

See also:

Using Navigation bar and Toolbar

Using the context menu

Editor Options

Keyboard Templates

Favorites editor

Find Text dialog

Replace Text dialog


Using the context menu

The context menu of Query Data area contains execution commands, most of the standard text-processing functions (Cut, Copy, Paste, Select All) and functions for working with the query as a whole, e.g. you can move the cursor to a particular line, change the case of selected text, view the query properties or print the text of the query. Each of these operations can be also performed with the corresponding hot keys used.

Implementation of the Find Text / Replace Text dialogs and Incremental search bar contributes to more efficient work with the SQL code.

Find the complete list of Query Data context menu items below. The context menu allows you to:

  • add the selected text to dictionary or correct text (see Spell checking for details);
  • execute the query/selected text/text under cursor, and reset execution point (if necessary);
  • manage markers: Drop Marker, Collect Marker, Swap Marker;
  • toggle bookmarks allowing you to navigate through the query text and jump to a line with a particular number;
  • perform editing operations: Undo/Redo, Cut, Copy, Paste, Select all;
  • perform search and replace operations;
  • save/load a query to/from an external *.sql file;
  • perform preview/print operations;
  • use the Quick code group allowing you to format the selected code using SQL Formatter to make the code easier to read, toggle comments for code fragments, change case of the selected text, indent/unindent code lines;
  • add the query to the Favorite Queries list;
  • open the Editor Options dialog.

SQL Editor - Using the context menu

See also:

Working with Query Data area

Executing queries


Viewing query plan

Using SQL Manager for PostgreSQL, you can view the plan for each of the queries created and executed in the application. The query plan is available within the corresponding Plan tab.

To view the Plan of a query, open the query in Query Data and use the btnExplainQuery Explain query item of the Navigation bar or toolbar.

The Plan tab allows you to view the sequence of actions performed by the database server in the process of the query execution, and the amount of system resources used for the query execution.

SQL Editor - Viewing query plan

The Operation panel below displays the operations as a tree list with the following columns: Operation Info, Operation, Start-up Cost, Total Cost, Number of Rows, Row Width, Startup Time, Total Time, Real Number of Rows, Loops.

Right-click within the panel to display the context menu allowing you to configure the set of visible columns or export the plan to any of supported formats.

If necessary, you can specify that the Plan tab appears automatically upon query execution in Query Data: select the CheckBox Explain query on execution option available within the Tools | Query Data section of the Environment Options dialog.

You can also view the execution plan as text at the bottom of the current tab: select the Verbose option available in the Explain query menu on the toolbar of Query Data.

The menu also allows you to enable the Analyze option to make the query execution plan more detailed (with execution time included).

See also:

Query Data options

Executing queries


Adding objects to query

An object can be placed to query from DB Explorer. Just drag-and-drop the required object from DB Explorer tree or from SQL Assistant to editor. Define statement for the object in the appeared window.

Note: You can drag-and-drop objects from DB Explorer to Query Designer too.

DB Explorer - Insert to Editor

Use the Statement list to define statement for the object: Name, SELECT, INSERT (parameters are used instead of values), UPDATE, DELETE, CREATE, DROP, Columns, List, Name and Type.

You can define alias for an object and prefix for variable in the respective fields.

See also:

Query parameters

Query Designer


Using object links

Objects that exist in the database are highlighted in the text as hyperlinks. You can open an object in the appropriate editor by clicking the object name in the text with the Ctrl key pressed.

SQL Editor - Using object links

Please note that you can change the way highlighted objects look in the editor: use the Color section of the Editor Options dialog.

See also:

Working with Query Data area

Editor Options


Executing queries

When all the query parameters are set, you can immediately execute the query in Query Data editor.

To execute a query, click the btnExecuteQuery Execute item of the Navigation bar. You can also use the context menu or F9 hot key for the same purpose.

If the SQL syntax is correct, the query is executed and, in case the query statement is supposed to return data (e.g. as SELECT statement), the returned dataset appears within the Results tab. The position of the tab depends on the Results on Edit tab / Results on separate tab selection in the Navigation bar.

Hint: Ctrl+D enables/disables the Results on Edit tab option.

If SQL syntax of the query contains any errors, the query execution is stopped and the corresponding error message is displayed in the status bar area at the bottom of the editor window.

SQL Editor - Executing queries

By default, data returned by a query are displayed as a grid (see Data View for details). The context menu of the grid allows you to Export Data, Export as SQL Script.

SQL Editor - Viewing results

See also:

Data View

Export Data

Export as SQL Script


Viewing query logs

This tab allows you to view the query log. The log is available within the Logs tab of Query Data editor.

Using this tab you can view log entries containing the following details:

  • date and time of the query execution;
  • text of the query;
  • number of rows fetched and fetch time, or the text of the error (if any).

Date/time and the execution result information are embedded as code comments conforming with the rules of SQL.

With the help of the context menu the log can be printed, saved to file or cleared. You can also use a number of Query Data editor context menu generic functions.

SQL Editor - Viewing query logs

See also:

Executing queries

Using the context menu


Favorites editor

For your convenience the Favorite Queries list is implemented in SQL Manager for PostgreSQL. This list is available within the iconFavoriteQueries Favorite Queries node of Database Explorer and allows you to store the most frequently used SQL queries in one location.

To add a query to the Favorite Queries list, use the [image] Add to Favorite Queries Navigation bar item in Query Data. The corresponding item is also available in the context menu of Query Data working area.

You can edit any of your Favorite Queries using Favorites editor.

SQL Editor - Favorites editor

Name

Set the name of the Favorite query.

Storage

Specify where the Favorite query will be stored: in Windows Registry or in the Database. In case of Database storage "public"."pgmfavorites" table is created to store queries.

NB: If you store Favorite queries in the Windows Registry then they can be lost after the Windows reinstall. To avoid this problem save the registry branch or store Favorite queries in a database.

See also:

Managing Favorite queries

Working with Query Data area


Design Query

Query Designer is implemented in SQL Manager for PostgreSQL for building queries visually. The tool allows you to create and edit queries without deep knowledge of SQL. You can also prepare and execute queries, and view the results of their execution.

To open Visual Design Query, select the Tools | Design Query main menu items or use the corresponding btnShowQueryBuilder toolbar buttons.

  • Using Navigation bar and Toolbar
  • Working with diagram area
  • Joining two database objects by fields
  • Setting the selection criteria
  • Setting output fields for selection
  • Setting the grouping criteria
  • Setting parameters of sorting
  • Working with editor area
  • Executing queries and viewing results
  • Viewing query plan

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Query Data

Query parameters

Design Query options


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Design Query.

Query Builder - Using Navigation bar

Database

iconDB select a database for the query

General

iconExecute execute the current query

view estimated query execution plan

clear the query

create a view

iconOptions configure Design Query with the Design Query Options page of the Environment Options dialog

iconRestoreDefaultSize restore the default size and position of the builder window

Objects

iconDBExplorer browse objects of the database; you can also add tables and views to the diagram using drag-and-drop operations

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with queries:

Visual Builder

iconLoadFromFile load a diagram from a *.vqb file using the Open diagram dialog

iconSaveToFile save the diagram to a *.vqb file using the Save diagram as... dialog

Edit

iconLoadFromFile load a query from an *.sql file using the Open SQL File dialog

iconSaveToFile save the query to an *.sql file

Data Management

iconCommit commit transaction

iconRollback rollback transaction

Note: These actions are available if the CheckBox Use transactions in object editors, Query Data and Design Query option is checked in the Database Registration Info | Data options dialog.

export the returned dataset using Export Data Wizard

export the returned dataset as SQL Script using the Export as SQL Script wizard

NB: You can enable\disable Toolbars and Navigation bars at Environment options.

See also:

Working with diagram area

Query execution


Working with diagram area

The main working area of Design Query editor is the diagram area available within the Builder tab. Here you can create a query by placing the database tables and views onto the area, and edit it by selecting the required data fields and setting links between objects.

To add an object to the query, you can simply drag it from the DB Explorer tree to the diagram area.

To include a field in the query, check the corresponding box located to the left from the field name in the list, or just double-click it. To include all fields of the table/view, check the box located to the left of the table/view caption. If you do not check any fields, the SQL statement is generated as SELECT * FROM <table/view_name>, i.e. all the fields are included in the query.

To collapse/expand the list of table/view fields, click the minimize/maximize button at the object caption.

To exclude a field from the query, uncheck the respective box. In order to remove the entire table/view from the query, close it by clicking the corresponding cross-button at the object caption, or right-click the object and select Delete from the context menu. You can also select the object and press the Del key.

To edit the alias of a table/view, double-click the object caption and enter the new name, or right-click the object and select Rename from the context menu.

Query Builder - Working with diagram area

Design Query allows you to create complex queries consisting of two or more queries combined in one with the UNION operator, or add nested queries. The panel to the left of the diagram area displays the tree of subqueries.

To add a query, right-click within the tree of subqueries area and select Add union from the context menu. A tab for the new query will appear in the diagram area.

To remove a query from the tree, right-click the query and select Delete union from the context menu.

To add the UNION ALL operator to the query, right-click the newly added query and select the corresponding context menu item.

Visual Query Builder - Union

Note: Depending on which query type you need to execute, you can select one from the drop-down list above the tree of subqueries: Select, Insert, Update, or Delete.

Visual Query Builder - Selecting query type

See also:

Joining two objects

Working with the editor area

Query execution


Joining two objects

The diagram area allows you to associate two objects by their columns: this operation is performed by dragging a field from one object list to another. This will set a link between these objects by the selected fields. It is indicated by a bidirectional arrow between the linked fields.

Query Builder - Joining two objects

You can view the link properties of objects association: set the mouse cursor over the linking arrow, and a hint containing the association condition will popup after a short delay.

To edit the link properties, double-click the linking arrow or right-click it and select the Property popup menu item. The Link properties dialog allows you to change the association condition by choosing it from the drop-down list (=, >, <, >=, <=, <>).

Query Builder - Link properties

For your convenience the CheckBox Include all option is available for each object of the association:

if the option is enabled for the left table, the LEFT JOIN operator will be used for the association;

if the option is enabled for the right table, the RIGHT JOIN operator is used for the association;

if the option is enabled for neither of the tables, the INNER JOIN operator is used for the association.

if the option is enabled for both of the tables, the FULL OUTER JOIN operator is used for the association.

Click OK to apply the changes you have made.

To remove a link between objects, right-click the linking arrow and select the Delete link popup menu item.

To add a point to the link line, right-click the linking arrow and select the Insert point popup menu item. Using the point you can move the link line easily. The point does not cause any changes to the query, it is only used for the diagram representation and makes visual building handy and more comprehensible.

Visual Query Builder - Link menu

See also:

Working with diagram area

Setting criteria


Setting criteria

Use the Criteria tab to set the selection conditions.

The way the conditions are used is set in the upper string of the area (All, Any, None or Not all of the following are met). Click the green link to change it.

Visual Query Builder - Criteria menu

To add a condition, click the ellipsis EllipsisButton button on the left, and select the Add condition popup menu item.

Edit the condition by clicking the elements of the condition pattern and setting the necessary values. Clicking the numbered button to the left of the condition string activates the popup menu which allows you to add a new condition at the same enclosure level, make composite condition by adding a new enclosure level, delete the current condition, expand or collapse enclosure levels of the condition (if the condition is composite).

Visual Query Builder - Condition menu

A simple condition pattern contains three elements: an argument, a condition operator and a second argument (if required for the condition).

Clicking each element field allows you to set its value. You can add a field by drag-and-dropping it from the working area to Criteria, Selection, Grouping criteria or Sorting tabs. When clicking an argument field, you can edit the argument as a text string: set an object name or a certain value in this field. Right-clicking the field in the edit mode activates the popup menu with the Insert field (also called by the Shift+Enter shortcut; this item allows you to select a field from the list of all the table fields) and Insert query (this item adds a nested query) items.

Query Builder - Setting criteria

Clicking the condition operator field activates the popup menu from which you can select the operator you need.

See also:

Setting output fields

Setting grouping criteria

Setting sorting parameters


Setting output fields

The Selection tab displays the output fields of the query as a grid.

The grid allows you to edit the names of the query output fields, specify their display order and set the aggregate functions for each field. To remove a field from the list, right-click the field row and select the Delete current row popup menu item.

Visual Query Builder - Selection field menu

The popup menu also allows you to insert a nested query and add a CASE clause. To edit the CASE clause, use the CASE END AS dialog.

Query Builder - Setting output fields - CASE

To change the input query field, click it and then type the field name or select it from the drop-down list.
To change the output query field name, set the cursor at the corresponding column and type the required field name.

To reorder fields in the list, use the [image] [image] buttons.

Query Builder - Setting output fields

To set an aggregate function for a field, click the field row within the Aggregate column, and then type in the function name or select one from the drop-down list (SUM, MIN, MAX, AVG, or COUNT).

The Grouping column displays the grouping state for each of the output fields.

CheckBox2 Select only unique records

If you check this option, the duplicate records (if any) are not included into the query result (i.e. the DISTINCT keyword is added to the SQL query text).

See also:

Setting criteria

Setting grouping criteria

Setting sorting parameters


Setting grouping criteria

The Grouping criteria tab allows you to set conditions for grouping query records.

The grouping condition pattern fields are set in the same way as those of the Criteria pattern.

Query Builder - Setting grouping criteria

These conditions will be included in the HAVING statement of the generated SQL query.

See also:

Setting criteria

Setting output fields

Setting sorting parameters


Setting sorting parameters

The Sorting tab allows you to set sorting parameters for the records returned by the query.

The working area contains the Output fields list (at the left) which represents all fields of the objects used in the query, and the Sorted fields list (at the right) which contains the fields to sort records by.

To move a field from one list to another, drag the selected field or use the Add and Remove buttons: Items - Move to Selected Items - Move all to Selected Items - Move to Available Items - Move all to Available .

To change the sorting order for a sorted field, select the field in the Sorted fields list and move it using the Up and Down buttons.

To change the sorting direction, select the field in the Sorted fields list and switch the direction (Ascending, Descending) using the corresponding A..Z/Z..A button.

Query Builder - Setting sorting parameters

See also:

Setting criteria

Setting output fields

Setting grouping criteria


Working with the editor area

The Editor area of Query Designer is available within the Edit tab and is provided for working directly with the SQL query text which is generated automatically while you build the query visually.

You can edit this text according to the rules of SQL, and all the changes will be displayed within the Builder tab respectively.

To learn more about the Query Data features available within the Edit tab, see Working with Query Data editor area.

Query Builder - Working with editor area

See also:

Working with diagram area

Query execution

Query Data


Query execution

When all the query parameters are set, you can immediately execute the query in Design Query editor.

To execute a query, click the btnExecuteQuery Execute query item of the Navigation bar. You can also use the F9 hot key for the same purpose.

If the query parameters are specified correctly, the query is executed and, in case the query statement is supposed to return data (e.g. as SELECT statement), the returned dataset appears within the Result tab.

If SQL syntax of the query contains any errors, the query execution is stopped and the corresponding error message is displayed in the status bar area at the bottom of the Design Query window.

By default, data returned by a query are displayed as a grid (see Data View for details). The context menu of the grid allows you to Export Data, Export as SQL Script.

Query Builder - Viewing results

See also:

Working with diagram area

Working with the editor area

Data View


Viewing query plan

Using SQL Manager for PostgreSQL, you can view the plan for each of the queries created and executed in the application. The query plan is available within the corresponding Plan tab.

To view the Plan of a query, open Design Query and use the btnExplainQuery Explain query item of the Navigation bar or toolbar.

The Plan tab allows you to view the sequence of actions performed by the database server in the process of the query execution, and the amount of system resources used for the query execution.

Query Builder - Viewing query plan

The Operation panel below displays the operations as a tree list with the following columns: Operation Info, Operation, Start-up Cost, Total Cost, Number of Rows, Row Width, Startup Time, Total Time, Real Number of Rows, Loops.

Right-click within the panel to display the context menu allowing you to configure the set of visible columns or export the plan to any of supported formats.

The area at the bottom displays the execution plan as text.

See also:

Query execution


Query parameters

Both Query Data and Design Query support parameters usage inside the query text. A parameter is a kind of variable for which a value can be specified just before the query execution. In the query text the parameter should appear as an identifier with a colon (':') at the beginning, e.g.

SELECT * FROM MYTABLE WHERE ID = :param1;

Note: The Allow using of parameters in query text option should be checked on the Tools page of the Environment Options dialog for this feature to be enabled.

See also:

Query Data

Design Query


Input parameters dialog

The Input Parameters dialog is used to specify the query parameters as well as values of the input parameters of the query before execution.

Query parameters - Input parameters dialog

Click OK button to apply the values and execute the query or click Cancel button to abort execution.


Data Management

Table data and query results are displayed on the Data or Results tab of Table Editor, Query Data, Design Query editors, etc.

Data can be displayed in one of the following modes: Grid View, Form View, Print Data, BLOB View. See Data View to learn more about these modes. You are also provided with a number of filtering tools when working with your data.

  • Data View
  • Custom Filter
  • Filter Builder dialog

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Change Management

Query Management Tools

Import/Export Tools

Database Tools

Services

Options

How To...


Data View

SQL Manager for PostgreSQL provides you with powerful tools for viewing, editing and printing data from tables and queries:

  • table / view data are available within the Data tab of Table Editor / View Editor correspondingly;
  • upon a query execution the returned dataset appears within the Result(s) tab of Query Data / Design Query (in Query Data the position of the tab depends on the Results on Edit tab / Results on separate tab selection in the Navigation bar).

The data can be displayed in one of four available modes: Grid View, Form View, Print Data and BLOB View. The status bar at the bottom displays the number of records in the current dataset, the time the records were fetched by the application and the status of the records (whether the data are read-only or editable).

Please see the succeeding chapters to learn how to work with your data in the simplest and most efficient way.

  • Using Navigation bar and Toolbars
  • Grid View
  • Form View
  • Print Data
  • BLOB View
  • Applying changes

See also:

Custom Filter

Filter Builder dialog

Table Editor

View Editor


Using Navigation bar and Toolbars

When the Data tab (in Table Editor, View Editor) or the Result(s) tab (in Query Data, Design Query) is selected, the Navigation bars of these tools contain the Data Management group which allows you to:

Data View - Using Navigation bar

export data

export data as SQL script

import data (in Table Editor, View Editor only)

save data (in Table Editor only)

load data (in Table Editor only)

Items of the Navigation bar are also available on the ToolBar. To enable the toolbar, open the Environment Options dialog, proceed to the Windows section there and select RadioButton Toolbar (if you need the toolbar only) or RadioButton Both (if you need both the toolbar and the Navigation bar) in the Bar style for child forms group.

The Navigation pane contains toolbars allowing you to:

Data View - Navigation pane

  • go to the first record of the dataset;
  • go to the previous page;
  • go to the previous record;
  • go to the next record;
  • go to the next page;
  • go to the last record of the dataset;
  • insert a new record (in Table Editor only);
  • delete the selected record (in Table Editor only);
  • edit the selected record (in Table Editor only);
  • post edit (in Table Editor only);
  • cancel edit (in Table Editor only);
  • refresh data;
  • set bookmark;
  • go to saved bookmark;
  • call the Filter Builder dialog;
  • search for a string in the currently selected column data;
  • enable/disable including data of descendant tables;
  • specify the maximum number of records (record limit) for displaying data (in Table Editor, View Editor only);
  • navigate within the dataset using the specified record limit (in Table Editor, View Editor only).

The Toolbar of the Print Data mode allows you to:

Data View - Print Data - Toolbar

  • customize the report using Report Formatter and the Report Options dialog;
  • load a report from an external *.rps file;
  • save the current report to an external *.rps file;
  • print the report using the default printer;
  • set printing options using the standard Print dialog;
  • call the Page Setup dialog;
  • show/hide report thumbnails;
  • customize the Report Title;
  • add Date and Time, Page Numbering, show/hide empty pages;
  • shrink the report to the page;
  • specify background color;
  • zoom in/out, setup zoom, zoom page width, whole page, two/four/multiple pages;
  • select the active page of the report;
  • go to first/previous/next/last page of the report.

The Toolbar of the BLOB View mode allows you to:

Data View - BLOB View - Toolbar

  • select a BLOB column;
  • select encoding (ANSI, UTF-8, UNICODE-16);
  • load BLOB content from an external file;
  • save the BLOB column content to an external file;
  • cut/copy/paste selected text to/from clipboard (enabled for the Text and Rich Text tabs only);
  • undo changes;
  • print the text (enabled for the Text, Rich Text and HTML tabs only);
  • select font to be applied to the selected text (enabled for the Rich Text tab only);
  • select font size to be applied to the selected text (enabled for the Rich Text tab only);
  • make the selected text bold/italic/underlined (enabled for the Rich Text tab only);
  • align left/center/right (enabled for the Rich Text tab only);
  • add/remove list bullets (enabled for the Rich Text tab only).

See also:

Grid View

Form View

Print Data

BLOB View

Applying changes

Customize toolbars and menus


Grid View

By default, data returned by a query is displayed as a grid. It is indicated by the Grid View tab selected on the View mode panel at the bottom of the Results area of the window.

When in the Grid View mode, the columns correspond to the columns and the rows correspond to the records.

If more convenient, you can change the order of the columns by dragging their headers horizontally. Clicking the column caption sorts data by the values of this column in the ascending or the descending mode. The navigation pane at the top of the grid allows you to browse the data quickly, to insert, update and delete records, and to set a filter for the records using the Filter Builder dialog and other tools.

The Navigation bar of the parent window, toolbars and the context menu of the grid provide you with a number of data management functions: Export Data, Import Data, Export as SQL Script and more.

  • Customizing columns
  • Grouping and sorting data within the grid
  • Filtering records
  • Using the context menu
  • Working in multi-level mode
  • Browsing data in card view
  • Column Summary
  • Copying records

Data View - Grid View

Hint: To increase the speed of opening tables and views with extremely large number of records, you can use options of the Limit options in table and view editors group available in the Grid | Data Options section of the Environment Options dialog.

See also:

Using Navigation bar and Toolbars

Form View

Print Data

BLOB View

Applying changes


Customizing columns

Selecting visible columns

When working in the Grid View mode, you can specify which columns of the current dataset will be visible. Click the btnSelectVisibleColumns button available in the top left corner of the data grid and select/deselect columns in the drop-down list to specify their visibility/invisibility.

Data View - Grid View - Selecting visible columns

Changing columns order

For your convenience the possibility to change the order of the columns in the data grid is available. To reorder columns, drag a column header horizontally to a place in between two other column headers indicated with green arrows.

Data View - Grid View - Changing columns order

See also:

Grouping data

Filtering records

Working in multi-level mode

Working in card view mode

Column Summary


Grouping and sorting data

In order to sort data, do the following:

open data at the Data or Results tab, choose the column by which you need to sort data and click the column title.

If the column was not sorted, the first click will sort it in the ascending order and the second one - in the descending order.

Clear Sorting

To cancel the sorting, open the context menu by right-clicking the necessary column and choose the Clear Sorting item, or press the Ctrl button and click the column title.

If necessary, you can group the data in grid by any of the columns.

This operation is performed by dragging the column header to the gray "Group by" box area at the top. In order to display this area, select the CheckBox Show "Group by" box option available in the Grid section of the Environment Options dialog.

When grouping by a column is applied to the grid, all the records are displayed as subnodes to the grouping row value as displayed in the screenshot below. The grouping row can contain the column summary information specified in the Group header group of the Column Summary dialog.

To reverse grouping, just drag the column header back.

Hint: While dragging the column header back, you can also change the column position.

Data View - Grid View - Grouping data

If necessary, you can group data by two or more columns. In this case column headers are displayed hierarchically, and data are grouped by these columns in the order the column headers appear in the "Group by" area.

Data View - Grid View - Grouping data by two columns

See also:

Customizing columns

Filtering records

Working in multi-level mode

Working in card view mode

Column Summary


Filtering records

A number of filtering facilities are implemented in the grid for your convenience. You can filter records in the grid in either of the following ways:

  • right-click a row and select the Quick Filter context menu item to filter records by the current value of the selected column;

Data View - Grid View - Quick Filter

  • click the Arrow-Down button next to the column caption to display the drop-down list and select any of the column values to filter records by this value of the selected column;

Data View - Grid View - Filtering records

or

  • click the Arrow-Down button next to the column caption to display the drop-down list, then select the Custom item and build a simple filter using the Custom Filter dialog;
  • use the Set filter btnSetFilter button on the navigation pane to invoke the Filter Builder dialog and create a composite filter using the dialog.

After the filter is set, the gray filtering panel becomes visible at the bottom of the grid. This panel allows you to see the active filtering condition and easily enable or disable it using the checkbox on the left. The Arrow-down button opens the drop-down menu which allows you to browse the filter history for this dataset.

If necessary, you can click the Customize... button on the right to customize your filter and add more complicated filtering conditions within the Filter Builder dialog.

Data View - Grid View - Filtering records - Filtering panel

To remove the current filter, click the Close btnClose button.

See also:

Customizing columns

Grouping and sorting data

Custom Filter

Filter Builder dialog


Using the context menu

The context menu of the grid is aimed at facilitating your work with data: you can perform a variety of operations using the context menu items:

  • copy the selected cell value to Windows clipboard;
  • paste the clipboard content to the currently selected cell;
  • copy/paste multiple records;
  • data manipulation: Export Data from the table, Import Data to the table, Export Data as SQL Script, Save Data, Load Data;
  • set/disable Quick Filter;
  • clear sorting;
  • set a value for the selected cell: NULL, Empty string (for string columns), Now (for TIME columns), "Zero" (for DATE columns);
  • edit the BLOB value or save the BLOB to file using BLOB viewer/editor;
  • expand/collapse grid levels and navigate within the tabs;
  • manage grid levels: add a new grid level, delete the current grid level (this item is enabled only when the detail level exists and is currently focused);
  • switch to the Card View mode;
  • view Column Summary;
  • select visible/invisible columns of the dataset;
  • fit column width for better representation;
  • specify the grid mode: Load All Rows, Load Visible Rows, Default;
  • view/edit grid properties.

Data View - Grid View - Using the context menu

Note: If the CheckBox Show editor immediately and CheckBox Always show editor options on the Environment options | Grid tab are checked then the context menu of a grid can be evoked by selecting the necessary cell and right-clicking the table header. Otherwise, right-clicking the cell evokes the cell editing menu.


Working in multi-level mode

One of unique features of SQL Manager for PostgreSQL is the ability to work with data in multi-level mode to view and modify data in several related tables simultaneously.

To manage grid levels, right-click the grid and select the Grid Levels context menu group. Items of this group allow you to:

  • add a new grid level using Create Grid Level Wizard;
  • delete the current grid level;
  • switch between the ordinary Table View and the Card View modes.

Data View - Grid View - Working in multi-level mode

See also:

Using the context menu

Create Grid Level wizard


Create Grid Level wizard

Create Grid Level Wizard allows you to add a new detail level to the grid in order to get master-detail representation of your data.

To start the wizard, right-click the grid, select the Grid Levels context menu group and proceed to the Add Grid Level... item within this group.

  • Specifying master level
  • Selecting source table
  • Binding master and detail levels
  • Query parameterization
  • Setting additional parameters

Create Grid Level - Add Grid Level


Specifying master level

Use the drop-down list to select the table of the master level to which a new level will be added.

Source of new level data

Select the source type of the new level data: RadioButton Table or RadioButton Query.

Create Grid Level - Specifying master level

Click the Next button to proceed to the Defining source for detail level step to select a table for the detail level or input a query, depending on whether the RadioButton Table or the RadioButton Query option has been selected.


Defining source for detail level

If the RadioButton Table option has been selected at the previous step, you should now specify a table for the detail view using the Table name drop-down list. Set the CheckBox Show tables related by foreign keys only option to narrow the list of tables by including only tables linked by Foreign keys.

Create Grid Level - Defining source for detail level - Table

If the RadioButton Query option has been selected at the previous step, you should now enter a query that will be used as the source of the new grid level. If necessary, you can use Design Query to build the SQL query visually.

Create Grid Level - Defining source for detail level - Query

Click the Next button to proceed to the Binding master and detail levels step of the wizard.


Binding master and detail levels

Define pairs of columns to link the Master Level and the Detail Level data sources:

  • select a column in the Master Level Key Columns list;
  • select a corresponding column in the Detail Level Key Columns list;
  • click Add to set correspondence between the selected columns.

The newly created correspondences are listed in the Links Between Master and Detail Levels area. If necessary, you can delete any correspondence using the Remove button.

The From Foreign Key... menu is available if the CheckBox Show tables related by foreign keys only option has been selected at the previous step. This menu allows you to select the foreign key to be used for identifying master-detail levels (if the table has more than one foreign key relation).

Create Grid Level - Binding master and detail levels

Click the Next button to proceed to the Setting additional parameters step or to the Query parameterization step of the wizard if RadioButton Query was selected at the Specifying master level step of the wizard.


Query parameterization

If RadioButton Query was selected at the Specifying master level step of the wizard, you should now transform the query to a parameterized form that will be used in the 'Load visible rows' Grid Mode (see the Grid | Data Options section of the Environment Options dialog to get more information about grid modes offered by SQL Manager).

Create Grid Level - Query parameterization

Click the Next button to proceed to the Setting additional parameters step of the wizard.


Setting additional parameters

Level caption

Set the caption to be used for the new level in the grid.

Level type

Select the type of view you wish to be applied to the grid level: RadioButton Table view or RadioButton Card view.

Create Grid Level - Setting additional parameters

When you are done, click the Run button to complete the operation.


Working in card view mode

Depending on your preferences, you can represent data in the Table View or in the Card View modes.

To switch to the Card View mode of data representation, right-click the grid, expand the Grid Levels context menu group and select the Card View item within this group.

Data View - Grid View - Working in card view mode

See also:

Using the context menu


Column Summary

If necessary, you can select the Column Summary... context menu item to open the Column Summary dialog which allows you to set the summary for each particular column that will be displayed in the grid footer, group header and group footer areas.

Data View - Grid View - Column Summary

The Column list displays all columns of the dataset. Select a column and specify which information should be displayed in the grid as summary for this column:

RadioButton None

RadioButton Sum (for numeric types only)

RadioButton Minimum (for numeric and date/time types only)

RadioButton Maximum (for numeric and date/time types only)

RadioButton Count

RadioButton Average (for numeric types only)

Use the Number format edit boxes in each group to specify the preferable format for summary info representation.

See also:

Using the context menu


Copying records

When you copy several records to clipboard and paste them into the grid, you are offered to set correspondence between columns of the clipboard and columns of the target PostgreSQL table using the Associate Columns dialog.

Data View - Grid View - Associate columns

The Clipboard Columns and Grid Columns lists display the source and target dataset columns respectively. Set correspondence between the source clipboard columns and the table columns:

  • select a source clipboard column in the Clipboard Columns list;
  • select the corresponding column the target table in the Grid Columns list;
  • click the Add button to set correspondence between the selected columns;
  • the pair of columns appears in the Links between... list below;
  • repeat the operation for all the columns you need copy.

Use the Add All button to add all columns to the Links between... list on the basis of their order.

To remove a correspondence, select the pair of columns in the Links between... list and press the Remove button.

To remove all correspondences, press the Remove All button.

CheckBox First row is a header

This option specifies that the first row of the associated columns will be taken as the column header.


Form View

The Form View tab allows you to view data as a form. To activate this type of data view, select the Form View tab on the View mode panel at the bottom of the window.

The form displays the current record: field names on the left and the corresponding values on the right. If the fields are available for editing, you can edit the record directly on this form. The navigation pane at the top of the form allows you to browse the data quickly, to insert, update and delete records, and to set a filter for the records using the Filter Builder dialog.

Data View - Form View

Each field has a CheckBox Null checkbox which allows you to clear the field value and set it to NULL (if the field is nullable).

See also:

Using Navigation bar and Toolbars

Grid View

Print Data

BLOB View

Applying changes


Print Data

Using the Print Data tab you can view data in the way they are printed, in WYSIWYG mode.

When in Print Data mode, you are provided with a powerful context menu and toolbar allowing you to design a report, change the view scope, save reports and load previously saved ones, set report options, and specify a number of printing parameters using Report Formatter and the Page Setup dialog.

Data View - Print Data

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Using Navigation bar and Toolbars

Grid View

Form View

BLOB View

Applying changes


Page Setup

The Page Setup dialog allows you to specify a number of settings pertaining to the report page.

To open the dialog, use the [image] Page Setup button available on the toolbar.

Use the following tabs of the Page Setup dialog:

  • Page
  • Margins
  • Header/Footer
  • Scaling

When you are done, you can click the Print... button at the bottom to call the Print dialog.

See also:

Report Formatter

Setting report options

Print dialog


Page

The Page tab of the Page Setup dialog allows you to specify the paper, page orientation, print order and shading settings.

Data View - Print Data - Page Setup - Page

Paper

Select one of the standard paper types in the Type list, or specify custom width and height using the Dimension group (in inches or millimeters, depending on the unit of measure specified in the Options dialog).

Use the Paper source drop-down list to select the paper feed type.

Orientation

Select the preferable page orientation (your selection is illustrated in the chart on the left):

RadioButton Portrait

RadioButton Landscape

Print Order

Select the preferable order for printing report pages (your selection is illustrated in the chart on the left):

RadioButton Down, then over

RadioButton Over, then down

Shading

CheckBox Print using gray shading

If this option is selected, gray shading (along with black and white) will be used for printing the report.


Margins

The Margins tab of the Page Setup dialog allows you to specify the size of the margins and running titles.

Data View - Print Data - Page Setup - Margins

Use the spinner controls to specify the size of top / bottom / left / right margins and header / footer (in inches or millimeters, depending on the unit of measure specified in the Options dialog). The Preview area on the right illustrates the changes you have made.

If you have specified an improper value, you can click the Fix button to correct it.

To restore the default size values, click the Restore Original button.

Center on page

This group allows you to specify whether the text should be centered horizontally and/or vertically on the page.


Header/Footer

The Header/Footer tab of the Page Setup dialog allows you to specify properties of the header and footer running titles.

Data View - Print Data - Page Setup - Header and Footer

Header / Footer

Click the Font... button to specify font properties using the standard Font dialog. The font name and size are displayed in the gray area next to the Font... button.

Use the Background drop-down list to select the background color that will be applied to the page header/footer, or to customize the color using the Color and Fill Effects dialogs.

For each of the running titles you are provided with three separate text editing fields. You can use any, all or none of the fields to enter the header and footer text.

The Vertical Alignment group allows you to specify vertical alignment for the header/footer text according to any of the three available patterns.

Predefined Functions

This group allows you to add the following standard functions to the header and footer:

[Machine Name]

[User Name]

[Time Printed]

[Date Printed]

[Date & Time Printed]

[Page # of Pages #]

[Total Pages]

[Page #]

CheckBox Reverse on even pages

If this option is selected, the header and footer text will be reversed on even pages of the printing report.


Scaling

The Scaling tab of the Page Setup dialog allows you to specify the page scaling options.

Data View - Print Data - Page Setup - Scaling

Select the preferable scaling mode:

RadioButton Adjust to ... % normal size

Use the spinner control to set the percentage of the regular page size to which the page size will be adjusted.

RadioButton Fit to ... page(s) wide by ... tall

Use the spinner controls to set the maximum number of pages (by width and by height) on one page to fit its size.


Report Formatter

Report Formatter allows you to specify a number of settings pertaining to the printing form of the report.

To open the tool, click the [image] Design Report button available on the toolbar, or use the Ctrl+D shortcut.

Use the following tabs of the Format Report dialog:

  • View
  • Behaviors
  • Formatting
  • Styles
  • Preview
  • Cards
  • Charts

The Title Properties... button allows you to customize the report title using the Report Title dialog.

See also:

Page Setup

Setting report options

Print dialog


View

The View tab of the Format Report dialog allows you to specify report elements to show in the report.

Data View - Print Data - Report Formatter - View

Tick off the elements to show in the report (caption, bands, headers, footers, group footers, expand buttons, filter bar) and on every page of the report (caption, bands, headers, footers, filter bar).

The Preview area on the right illustrates the changes you have made.


Behaviors

The Behaviors tab of the Format Report dialog allows you to specify the way (behavior) the report elements will appear on the printing form.

Data View - Print Data - Report Formatter - Behaviors

Selection

CheckBox Process selection / CheckBox Process exact selection

Specify whether the text selection should or should not be processed (precisely) for the printing form.

Expanding

Tick off the elements to expand in the report: groups, details, cards.

Size

CheckBox Auto Width

If this option is selected, the table will be resized automatically to fit the page by width.

The Preview area on the right illustrates the changes you have made.


Formatting

The Formatting tab of the Format Report dialog allows you to specify Look and Feel, Refinements and Pagination options.

Data View - Print Data - Report Formatter - Formatting

Look and Feel

This setting determines the manner in which the cells are painted. Use the drop-down list to select the painting style that will be applied to the cells on the printing form:

Flat

Standard

UltraFlat

Refinements

Options of this group allow you to reduce the report size.

CheckBox Transparent graphics

If this option is selected, the images will be drawn transparent in the report.

CheckBox Display graphic as text

If this option is selected, text will be displayed instead of the images.

CheckBox Flat CheckMarks

If this option is selected, the checkboxes will be drawn flat.

Pagination

Specify the way pagination will be performed for the report: By TopLevel groups or One group per page.

The Preview area on the right illustrates the changes you have made.


Styles

The Styles tab of the Format Report dialog allows you to specify styles to be applied to the report elements.

Data View - Print Data - Report Formatter - Styles

CheckBox Use native styles

This option determines whether the native Windows style will be applied to the report elements.

Note: The Native style option is currently supported for the Windows® XP operating system only.

The elements list displays the names of all report elements, with background color and font properties specified by default. You can Use native styles for them or customize them according to your preferences.

To edit an element, select it in the list and use the buttons to the right to edit the style for it.

Click the Font... button to specify font properties using the standard Font dialog.

Click the Color... button to customize the background color using the standard Color dialog.

Click the Texture... button to load an image that will be used as the texture for the element.

To rollback the changes, click the Clear button.

To restore the default stylesheet properties, click the Restore Defaults button.

If you need to save the current style sheet, you can click the Save as... button.

These items are also available through the context menu of the elements list.

Style Sheets

Use the drop-down menu to select the style sheet you need. To manage the style sheets, use the corresponding buttons below: New..., Copy..., Delete..., Rename...

The Preview area on the right illustrates the changes you have made.


Preview

The Preview tab of the Format Report dialog allows you to specify report preview options.

Data View - Print Data - Report Formatter - Preview

CheckBox Visible

This option specifies visibility of the grouping rows.

CheckBox Auto height

If this option is selected, the table will be resized automatically to fit the page by height.

Max line count

Use the spinner control to specify the maximum possible number of lines.

The Preview area on the right illustrates the changes you have made.


Cards

The Cards tab of the Format Report dialog allows you to specify properties for the card view.

Data View - Print Data - Report Formatter - Cards

Sizes

CheckBox Auto Width

If this option is selected, the cards will be resized automatically to fit the page by width.

CheckBox Keep same width

Select this option to keep the card width fixed.

CheckBox Keep same height

Select this option to keep the card height fixed.

Spacing

This group allows you to specify horizontal and vertical spacing between cards.

Framing

CheckBox Border

This option specifies visibility of the card borders.

CheckBox Horizontal lines

This option specifies visibility of the horizontal lines (row delimiters) within cards.

CheckBox Vertical lines

This option specifies visibility of the vertical lines (column delimiters) within cards.

Shadow

Use the Color drop-down list to select the color that will be applied to the card shadows. If necessary, specify the color depth using the corresponding spinner control.

The Preview area on the right illustrates the changes you have made.


Charts

The Charts tab of the Format Report dialog allows you to specify options for the charts used in the report.

Data View - Print Data - Report Formatter - Charts

CheckBox Transparent

If this option is selected, the charts will be drawn transparent in the report.

The Preview area on the right illustrates the changes you have made.


Setting report options

Options dialog

The Options dialog allows you to specify a number of settings pertaining to the printing report.

To open the dialog, open the Design Report [image] menu available on the toolbar and select the Preferences item.

Data View - Print Data - Report options

Show

Tick off the elements to show in the printing report (margins, margins hints, margins hints while dragging).

Use the Measurement Units drop-down list to select the unit of measure that will be used in report settings: default, inches, or millimeters.

Zoom Parameters

CheckBox Zoom on roll with IntelliMouse

If this option is selected, you can zoom in/out by scrolling up/down (with a Microsoft® mouse or a compatible mouse used).

Zoom Step

Use the spinner control to specify the percentage of the original page size to be considered as one zoom step.

Use the Margins Color drop-down list to select the color that will be applied to the report margins.

Report Title dialog

The Report Title dialog allows you to specify the report title text and properties.

To open the dialog, use the Title... button available on the toolbar.

Data View - Print Data - Report options - Title

Mode

Use the drop-down list to select where the report title should be displayed on the first page, on every top page, or not displayed at all.

Text

Use the edit box to enter the text of the report title.

Properties

CheckBox Transparent

If this option is selected, the report title will be drawn transparent.

Use the Color drop-down list to select the color that will be applied to the report title (enabled if the CheckBox Transparent option is not selected).

Click the Font... button to specify title font properties using the standard Font dialog. The font name and size are displayed in the gray area next to the Font... button.

CheckBox Adjust on scale

If this option is selected, the title can be adjusted on scale.

Alignment

Use the Horizontally drop-down list to select the type of horizontal alignment to be applied to the report title: Left, Center, or Right.

Use the Vertically drop-down list to select the type of vertical alignment to be applied to the report title: Top, Center, or Bottom.

To restore the default title properties, click the Restore Defaults button.

Date and Time dialog

The Date and Time dialog allows you to specify the date/time formats to be used in the report.

To open the dialog, open the Title... menu available on the toolbar and select the Date and Time... item.

Data View - Print Data - Report options - Date and Time

Select the preferable values from the Available Date Formats and the Available Time Formats lists. If necessary, you can specify that the date/time will be updated automatically.

To apply the default date/time format, click the Default... button.

Page Number Format dialog

The Page Number Format dialog allows you to specify the formats for page numbers to be used in the report.

To open the dialog, open the Title... menu available on the toolbar and select the Page Numbering... item.

Data View - Print Data - Report options - Page Number Format

Select the preferable number format from the Number Format drop-down list.

Use the Page Numbering section to specify whether page numbering should continue from the previous section (if any) or start at the specified number.

To set the default numbering values, click the Default... button.

Zoom dialog

The Zoom dialog allows you to zoom the report page more better representation.

To open the dialog, open the Zoom [image] menu available on the toolbar and select the Setup zoom... item.

Data View - Print Data - Report options - Zoom

Select the preferable percentage of zoom value (500%, 200%, 150%, 100%, 75%, 50%, 25%, 10%) or specify one of frequently used values:

RadioButton Page Width

RadioButton Whole Page

RadioButton Two Pages

RadioButton Four Pages

RadioButton Many Pages (click the chart below and select the item you need)

If necessary, you can set a custom percent value using the Percent spinner control below.

The Preview area on the right illustrates the changes you have made.

See also:

Page Setup

Report Formatter

Print dialog


Print dialog

The standard Print dialog allows you to specify printing settings for the report in groups: printer, page range, copies.

To open the dialog, click the Print dialog btnPrintSetup button available on the toolbar, or use the Ctrl+P shortcut.

Data View - Print Data - Print dialog

When you are done, click the Print button to start printing.

If you need to change any page settings before printing, you can click the Page Setup... button at the bottom to call the Page Setup dialog.

See also:

Page Setup

Report Formatter

Setting report options


BLOB View

SQL Manager for PostgreSQL provides BLOB Viewer/Editor to view and edit BLOB (Binary Large Object) columns content. The BLOB Viewer/Editor can be invoked from the data grid within Table Editor, Query Data, Visual Design Query, etc.

  • Navigation within the BLOB Viewer/Editor
  • Viewing/Editing BLOB column as Hexadecimal dump
  • Viewing/Editing BLOB column as plain Text
  • Viewing/Editing BLOB column as Rich Text (RTF)
  • Viewing/Editing BLOB column as Image
  • Viewing/Editing BLOB column as HTML
  • Viewing/Editing BLOB column as XML
  • Viewing/Editing BLOB column as PDF
  • Viewing/Editing BLOB column as JSON

Data View - BLOB View

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Using Navigation bar and Toolbars

Grid View

Form View

Print Data

Applying changes


Navigation within BLOB Editor

The BLOB Viewer/Editor provides an ability to navigate within the records using DB Navigation buttons on the navigation pane at the top of the viewer window.

Using items of the navigation pane and the drop-down menu you can browse the data quickly, insert, update and delete records, set a filter for the records using the Filter Builder dialog, load new BLOB content and save the current content to files.

The toolbar allows you to switch the columns and perform a number of editing operations. The set of toolbar items depends on the current selection and view mode.

Data View - BLOB View - Navigation within BLOB Editor

See also:

Editing as Hexadecimal

Editing as Text

Editing as Rich Text

Editing as Image

Editing as HTML

Editing as XML

Editing as PDF

Editing as JSON


Editing as Hexadecimal

The Hexadecimal tab allows you to view/edit the BLOB data as hexadecimal.

The toolbar provides additional functionality for BLOB Viewer/Editor: use the Save to file btnSave and the Load from file iconLoadFromFile toolbar buttons to save the hexadecimal data to a file, or load data from a file.

Use the Ins key to switch between the Insert and Overwrite modes.

Data View - BLOB View - Hexadecimal

See also:

Navigation within BLOB Editor

Editing as Text

Editing as Rich Text

Editing as Image

Editing as HTML

Editing as XML

Editing as PDF

Editing as JSON


Editing as Text

The Text tab allows you to view/edit the BLOB data as plain text.

The toolbar provides additional functionality for BLOB Viewer/Editor: use the Save to file btnSave and the Load from file iconLoadFromFile toolbar buttons to save the text to a *.txt file, or load text from a file. Additionally, you can use the Cut, Copy, Paste, Select All, Undo, Word Wrap context menu items for editing the text efficiently, and the Print context menu item to print the content of the Text tab.

Data View - BLOB View - Text

See also:

Navigation within BLOB Editor

Editing as Hexadecimal

Editing as Rich Text

Editing as Image

Editing as HTML

Editing as XML

Editing as PDF

Editing as JSON


Editing as Rich Text

The Rich Text tab allows you to view/edit the BLOB data in Rich Text format (RTF).

The toolbar provides additional functionality for BLOB Viewer/Editor: use the btnSave Save to file and the iconLoadFromFile Load from file toolbar buttons to save the Rich Text to a *.rtf file, or load text from a file. Additionally, you can use the Cut, Copy, Paste, Select All, Undo context menu items for editing the text efficiently, and the Print context menu item to print the content of the Rich Text tab.

Data View - BLOB View - Rich Text

See also:

Navigation within BLOB Editor

Editing as Hexadecimal

Editing as Text

Editing as Image

Editing as HTML

Editing as XML

Editing as PDF

Editing as JSON


Editing as Image

The Image tab allows you to view the BLOB data as image.

The toolbar provides additional functionality for BLOB Viewer/Editor: use the btnSave Save to file and the iconLoadFromFile Load from file toolbar buttons to save the image to a *.png, *.wmf, *.ico or *.jpg file, or load an image from a file.

Data View - BLOB View - Image

See also:

Na vigation within BLOB Editor

Editing as Hexadecimal

Editing as Text

Editing as Rich Text

Editing as HTML

Editing as XML

Editing as PDF

Editing as JSON


Editing as HTML

The HTML tab allows you to view the BLOB data as HTML (Hyper-Text Markup Language format) - in the way this data would be displayed by your Internet browser.

The toolbar provides additional functionality for BLOB Viewer/Editor: use the Save to file btnSave and the Load from file iconLoadFromFile toolbar buttons to save the content as a *.html, or *.htm file, or load content from a file.

Data View - BLOB View - HTML

See also:

Navigation within BLOB Editor

Editing as Hexadecimal

Editing as Text

Editing as Rich Text

Editing as Image

Editing as XML

Editing as PDF

Editing as JSON


Editing as XML

The XML tab allows you to view/edit the XML (eXtensible Markup Language) data.

The toolbar provides additional functionality for BLOB Viewer/Editor: use the Save to file btnSave and the Load from file iconLoadFromFile toolbar buttons to save the content as *.xml or load XML content from a file.

Data View - BLOB View - XML

The XML content is represented as a tree-like structure consisting four editable fields: Name, Unique, Attributes and Value. You can edit data and modify the structure using drag-n-drop operations and items of the context menu.

Hint: Hold the Shift key when you drag-and-drop a node to insert it as a child one.

The context menu allows you to:

  • add a node (a child node relatively to the selected one);
  • remove the selected node;
  • copy the selected node source to clipboard;
  • cut the selected node;
  • copy the selected node;
  • paste a node from clipboard.

Press the Item attributes [image] button in the editing mode of an Attribute item to add or edit attributes.

Data View - BLOB View - XML - Item attributes

Use the btnAddItem btnRemoveItem buttons to add or remove an attribute. Click the required attribute name or value to edit.

See also:

Navigation within BLOB Editor

Editing as Hexadecimal

Editing as Text

Editing as Rich Text

Editing as Image

Editing as HTML

Editing as PDF

Editing as JSON


Editing as PDF

The PDF tab allows you to view the BLOB data as PDF.

The toolbar provides additional functionality for PDF Viewer/Editor: use the btnSave Save to file and the iconLoadFromFile Load from file toolbar buttons to save the image to a *.pdf file, or load file.

Data View - BLOB View - PDF

See also:

Navigation within BLOB Editor

Editing as Hexadecimal

Editing as Text

Editing as Rich Text

Editing as Image

Editing as HTML

Editing as XML

Editing as JSON


Editing as JSON

The JSON tab allows you to view the BLOB data as JSON.

The toolbar provides additional functionality for BLOB Viewer/Editor: use the btnSave Save to file and the iconLoadFromFile Load from file toolbar buttons to save the Rich Text to a *.txt file, or load text from a file. Additionally, you can use the Cut, Copy, Paste, Select All, Undo context menu items for editing the text efficiently, and the Print context menu item to print the content of the JSON tab.

Data View - BLOB View - JSON

See also:

Navigation within BLOB Editor

Editing as Hexadecimal

Editing as Text

Editing as Rich Text

Editing as Image

Editing as HTML

Editing as XML

Editing as PDF


Applying changes

After changes are done, click the Post Edit btnPostEdit button on the navigation pane to apply the changes or the Cancel Edit btnCancelEdit button to discard the changes.

Data View - Applying changes

See also:

Using Navigation bar and Toolbars

Grid View

Form View

Print Data

BLOB View


Custom Filter

The Custom Filter dialog is one of the filtering facilities implemented in Data View for your convenience.

To open the dialog, click the Arrow-Down button next to the column caption, and select the Custom item from the drop-down list.

Select a logical operator for checking the column values (like, is less than, is greater than, etc.) and set a value to be checked by this operator in the corresponding box on the right.

Data management - Custom Filter

If necessary, you can set the second condition and specify the relation between the two conditions: whether both of them should be satisfied (AND) or just any of them (OR). Use the '_' character to represent any single symbol, and use the '%' character to represent any series of symbols in the condition string.

See also:

Data View

Filter Builder dialog


Filter Builder dialog

The Filter Builder dialog is a powerful filtering tool implemented in Data View for your convenience.

The dialog is aimed at facilitating the procedure of creating and applying complex filter criteria for data. In addition, the tool allows you to save filter criteria to an external *.flt file for future use.

To open the Filter Builder dialog, use the btnSetFilter Set filter button on the navigation pane available within the Data tab of Table Editor and the Result(s) tabs of Query Data and Design Query.

  • Invoking the Filter Builder dialog
  • Adding a new condition to the filter
  • Setting filter criteria
  • Setting filter operator
  • Setting filter criteria values
  • Adding a new group
  • Setting group operator
  • Applying filter conditions

See also:

Data View

Custom Filter


Invoking the Filter Builder dialog

The Filter Builder dialog can be invoked in either of the following ways:

  • if a simple filter or the Custom Filter is being used, click the Customize... button on the gray filtering panel;

Filter Builder dialog - Invoking the Filter Builder dialog

  • use the Set filter btnSetFilter button on the navigation pane and create a composite filter using the dialog.

Data View - Navigation pane

The succeeding pages of this chapter are intended to illustrate usage of the Filter Builder dialog. Please see the instructions below to learn how to perform various operations in the easiest way.

See also:

Adding a new condition

Setting filter criteria

Setting filter operator

Setting filter criteria values

Adding a new group

Setting group operator

Applying filter conditions


Adding a new condition

Suppose we need to select data from the sample table Employee to view the list of male engineers belonging to the Engineering and Tool Design departments that were hired after 10/1/2007. These criteria are applied to the Gender, HireDate, Position and the DepID columns.

Click press the button to add a new condition - this will add a new condition to the criteria. Alternatively, you can click the Filter button and select the Add Condition popup menu item.

Filter Builder dialog - Adding a new condition

See also:

Invoking the Filter Builder dialog

Setting filter criteria

Setting filter operator

Setting filter criteria values

Adding a new group

Setting group operator

Applying filter conditions


Setting filter criteria

As we need to apply the filter criteria to the HireDate column, we click the column box (next to the ellipsis EllipsisButton button) to open the drop-down list displaying the available column names and select the HireDate item.

Filter Builder dialog - Setting filter criteria

See also:

Invoking the Filter Builder dialog

Adding a new condition

Setting filter operator

Setting filter criteria values

Adding a new group

Setting group operator

Applying filter conditions


Setting filter operator

Since we need the list of employees hired after 10/1/2007, we need to select the IS GREATER THAN operator from the corresponding drop-down list.

Filter Builder dialog - Setting filter operator

See also:

Invoking the Filter Builder dialog

Adding a new condition

Setting filter criteria

Setting filter criteria values

Adding a new group

Setting group operator

Applying filter conditions


Setting filter criteria values

Next, we need to specify value '10/1/2007' for the IS GREATER THAN operator.

Similarly, if, for example, we need to get the list of employees hired during the 9/1/2007 - 10/1/2007 term, we set the BETWEEN filter operator (this will add two empty value boxes to specify the inclusive range for the BETWEEN condition) and specify the range for the operator, i.e. the '9/1/2007' and the '10/1/2007' values in the corresponding value boxes.

It is possible to set the date value manually by typing it in, or using the date editor which is activated when you click the value box.

Filter Builder dialog - Setting filter criteria values

Editors used in value boxes are determined by the data type assigned to the corresponding columns.

See also:

Invoking the Filter Builder dialog

Adding a new condition

Setting filter criteria

Setting filter operator

Adding a new group

Setting group operator

Applying filter conditions


Adding a new group

Since we also need to get the list of male specialists-engineers (i.e. those registered in the Engineering and Tool Design departments and having an engineering-oriented position), we can add a complex filter condition combining simple conditions with the AND operator. (However, in this particular case we can just add them at the same root level as for the existing condition).

If you need to add a group of conditions, click the ellipsis EllipsisButton button for the HIRE_DATE condition and select the Add Group popup menu item.

Filter Builder dialog - Adding a new group

See also:

Invoking the Filter Builder dialog

Adding a new condition

Setting filter criteria

Setting filter operator

Setting filter criteria values

Setting group operator

Applying filter conditions


Setting group operator

Conditions of complex criteria can be combined with any of the four logical operators used: AND, OR, NOT AND, NOT OR.

In our case it is enough to click the group operator box and select the AND item from the drop-down menu.

Filter Builder dialog - Setting group operator

See also:

Invoking the Filter Builder dialog

Adding a new condition

Setting filter criteria

Setting filter operator

Setting filter criteria values

Adding a new group

Applying filter conditions


Applying filter conditions

Suppose we have created a condition within the new group. If we need, we can add more conditions at the same level and specify the required values using the value boxes. When the operation is completed, the Filter Builder dialog will look like in the screenshot below.

Click the Apply button to see the result of the filtering you have made, and click OK or Cancel to close the dialog with or without saving your filter conditions respectively.

Filter Builder dialog - Applying filter conditions

The Filter Builder dialog allows you to save filter criteria to and load them from external files. Clicking the Save As… or the Open… buttons activates the corresponding dialogs. Filter settings are stored in *.flt files.

Please be informed that a column in the file is referenced by its position within a view, hence filter settings cannot be correctly restored if columns have been deleted from the view after saving the filter to a file.

See also:

Invoking the Filter Builder dialog

Adding a new condition

Setting filter criteria

Setting filter operator

Setting filter criteria values

Adding a new group

Setting group operator


Import/Export Tools

Using SQL Manager for PostgreSQL you are provided with powerful tools to import and export data to/from your PostgreSQL database.

Export Data Wizard

Exports data to various supported formats including MS Excel, MS Access, RTF, HTML, PDF, CSV, XML and more.

Import Data Wizard

Imports data from any of supported formats: MS Excel, MS Access, DBF, TXT, CSV, XML and more.

Export Data as SQL Script

Exports data to an SQL script as a number of INSERT statements.

Save Data Wizard

Saves data to an external file with the COPY statement used.

Load Data Wizard

Loads data from an external file with the COPY FROM statement used.

Using templates

Facilitates using import/export wizards.

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Change Management

Query Management Tools

Data Management

Database Tools

Services

Options

How To...


Export Data Wizard

Export Data Wizard allows you to export data from a table / view or from a query result to any of supported formats (MS Excel, MS Access, MS Word, RTF, HTML, PDF, TXT, CSV, XML, DBF, etc.). You can save your settings as a template any time for future use.

To start the wizard, right-click the object in DB Explorer and select the Data Manipulation | [image] Export Data... context menu item.

Alternatively, you can open the Data tab of Table Editor / View Editor or the Result(s) tab of Query Data / Design Query, right-click the grid there and select the Data Manipulation | [image] Export Data of <object_name>... context menu item.

  • Setting name and format for the destination file
  • Selecting columns for export
  • Adjusting formats applied to exported data
  • Setting header and footer text for the destination file
  • Setting format-specific options
  • Setting common export options
  • Exporting data

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Import Data Wizard

Export as SQL Script

Save Data Wizard

Load Data Wizard

Using templates


Setting destination file name and format

This step of the wizard allows you to select the destination file format you need to export data into.

Destination format

Specify the format of the destination file. For details refer to Supported file formats.

Click the Next button to proceed to the Selecting columns for export step of the wizard.

Export Data - Setting destination file name and format

Destination file name

Type in or use the btnSaveAs button to specify the path to the file using the Save as... dialog. The file name extension changes automatically according to the selected Destination format.

Note: If the target file already exists, the application will show a warning dialog where you can choose the action you need.


Selecting columns for export

This step of the wizard allows you to select the table column(s) to be exported.

To select a column, you need to move it from the Available columns list to the Selected columns list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the columns from one list to another.

Export Data - Selecting fields for export

If you leave all the columns in the Available columns list, all columns of the table (except BLOBs) will be exported.

CheckBox Allow captions

Check this option if you need to export the column captions as well.

Click the Next button to proceed to the Adjusting data formats step of the wizard.


Adjusting data formats

This step allows you to customize formats applied to exported data.

Data formats

Edit the format masks to adjust the result format in the way you need: Integer, Float, Date, Time, DateTime, Currency, Boolean True, Boolean False, NULL string, Decimal separator, Thousand separator, Date separator, Time separator.

Export Data - Adjusting data formats

Hint: The formats used by default are specified in the Data Export section of the Environment Options dialog.

For more details refer to Format specifiers.

Click the Next button to proceed to the Setting header and footer step of the wizard.


Setting header and footer

Set Header text and Footer text for the result file. This text will appear at the beginning and at the end of the result file respectively.

Export Data - Setting header and footer

Click the Next button to proceed to Setting format-specific options.


Setting format-specific options

This step of the wizard allows you to customize Format-specific options:

  • Excel 97-2003 options
  • Access options
  • RTF options
  • HTML options
  • PDF options
  • TXT options
  • CSV options
  • XML options
  • MS Excel / ODS options
  • MS Word / ODT options

To get more information about the file formats, see the Supported file formats page.


Excel 97-2003 options

This step allows you to set options for the target MS Excel 97-2003 (*.xls) file.

You can customize Data format, Extensions and set Advanced options available within the corresponding tabs:

  • Data format
  • Extensions
  • Advanced

Export Data - Format-specific options - Excel

When you are done, click the Next button to proceed to Setting common export options.


Data format

The Data Format tab contains general options which allow you to adjust the format for each kind of Excel cells. This means that you can specify such parameters as font, borders, filling color and method, etc. for each entity (such as data column, header, footer, caption, data, hyperlink and so on) separately. Also it is possible to create styles to make the target Excel file striped by columns or rows.

  • Columns
  • Options
  • Styles

For your convenience the previews illustrating the changes are displayed in the Sample Group area on each page of Data Format tab.


Columns

Using the Columns tab you can set font options, border and fill options and aggregate functions for all the columns you want to export.

The Font tab allows you to specify properties of the font that will be used in the output Excel file cells.

Use the Font and Size drop-down lists to select the font and size to be applied to the output text.

Use the buttons below to set font color, make text bold, italicized, strikethrough text, set underline effects, specify text horizontal and vertical align.

Export Data - Format-specific options - Excel - Data Format - Fields

The Borders tab allows you to specify properties of the borders of the output Excel file cells.

Press the [image] [image] [image] [image] buttons on the left to show/hide the borders they indicate.

Use the drop-down list for each border to select the line type and the [image] button on the right to select the line color for each border.

Export Data - Format-specific options - Excel - Data Format - Fields - Borders

The Fill tab allows you to specify the fill pattern for the output Excel file cells.

Use the drop-down list to select the preferable fill pattern type.

Press the [image] button on the left to set the background color for the fill pattern.

Press the [image] button on the right to set the foreground color for the fill pattern.

Export Data - Format-specific options - Excel - Data Format - Fields - Fill

The Aggregate tab allows you to specify an aggregate function for the field in the output Excel file.

Select a function that will be applied to the field:

RadioButton None

RadioButton AVG

RadioButton MAX

RadioButton SUM

RadioButton MIN

Export Data - Format-specific options - Excel - Data Format - Fields - Aggregate

You can reset the changes any time using the Reset Item and the Reset All buttons.


Options

Using the Options tab you can set font options, border and fill options for all elements of the Excel sheet (header, caption, footer, aggregates and hyperlinks).

Export Data - Format-specific options - Excel - Data Format - Options

The font, borders and fill options are specified in the same way as for output Columns. For details refer to the Columns page.

You can reset the changes any time using the Reset Item and the Reset All buttons.


Styles

Using the Styles tab you can make a style template: set font options, border and fill options and save them.

To add a style template, click the Plus iconPlus button.

To delete a style template, select it and click the Minus iconMinus button.

To reorder style templates in the list, use the btnMoveItemUp btnMoveItemDown buttons.

To load a style template, click the iconLoadFromFile button.

To save the current style template, click the btnSave button.

If you have created or loaded more than one style template, they can be ignored, or used column-by-column or row-by-row (it depends on the Strip type selection).

Export Data - Format-specific options - Excel - Data Format - Styles

The font, borders and fill options are specified in the same way as for output Columns. For details refer to the Columns page.

You can reset the changes any time using the Reset Item and the Reset All buttons.


Extensions

The Extensions tab provides an ability to add hyperlinks and notes and to any cell of the target file, to specify a value of a cell, to create a chart and to merge cells.

Click the iconPlus Plus button to add an element;

click the iconMinus Minus button to delete an element.

  • Hyperlinks
  • Notes
  • Charts
  • Cells
  • Merged Cells


Hyperlinks

If you need to create a hyperlink:

  • set the cell coordinates (Col and Row);
  • specify whether this is a local link or URL;
  • enter the title of the hyperlink;
  • specify the target file location or address.

Export Data - Format-specific options - Excel - Extensions - Hyperlinks

Use the Col and Row spinner controls to specify the column and row for the hyperlink in the output file.

The Style group allows you to select the preferable hyperlink style:

RadioButton URL

RadioButton Local file (i.e. the file is located on your local machine or on a machine in the LAN)

Use the Title box to specify the hyperlink name.

The Target box lets you enter the path to the target file or URL. Use the [image] button to check whether the specified location is available.


Notes

If you need to create a note:

  • set the cell coordinates (Col and Row);
  • enter text of a note for the cell;
  • set the font and fill properties using the corresponding tabs.

The Base tab allows you to specify basic properties of the note to be added to the output Excel file.

Use the Col and Row spinner controls to specify the column and row for the note in the file.

Use the edit-box below to enter the text of the note.

Export Data - Format-specific options - Excel - Extensions - Notes - Base

The Font tab allows you to specify properties of the font that will be used for the note.

Use the Font and Size drop-down lists to select the font and size to be applied to the output text.

Use the buttons below to set font color, make text bold, italicized, strikethrough text, set underline effects, specify text horizontal and vertical align.

The Orientation group allows you to select the note text orientation:

RadioButton No rotation

RadioButton Top to bottom

RadioButton Counterclockwise

RadioButton Clockwise

Export Data - Format-specific options - Excel - Extensions - Notes - Font

The Fill tab allows you to specify the fill type and transparency for the note.

The Fill Type group allows you to select whether the fill color will be solid or gradient:

RadioButton Horizontal

RadioButton Vertical

RadioButton Diagonal up

RadioButton Diagonal down

RadioButton From corner

RadioButton From center

Press the [image] button to set the background color for the fill pattern.

Press the [image] button to set the foreground color for the fill pattern.

The Transparency control allows you to set the transparency degree for the note. Move the slider between the 0% and 100% threshold values to select the required transparency value within this scope.

Export Data - Format-specific options - Excel - Extensions - Notes - Fill


Charts

If you need to create a chart:

  • enter the chart title;
  • select the chart style;
  • set the legend position;
  • specify if you want to show the legend;
  • specify if you want to set the chart color automatically;
  • define the chart position and category labels using the corresponding tabs.

The Base tab allows you to specify basic properties of the chart to be added to the output Excel file.

Use the Title box to specify the chart name.

Use the Style drop-down list to select the preferable chart style (Column, Column 3D, Bar, Bar 3D, Line, Line Mark, Line 3D, etc.).

The Legend position group allows you to specify position of the chart legend:

RadioButton Bottom

RadioButton Top

RadioButton Left

RadioButton Corner

RadioButton Right

CheckBox Show legend

This options specifies whether the chart legend will be visible or not.

CheckBox Auto color

If this option is selected, each series will be automatically differentiated with different colors on the chart, otherwise one color will be applied for all series.

Export Data - Format-specific options - Excel - Extensions - Charts - Base

The Position tab allows you to specify properties pertaining to the chart position on the output file sheet.

RadioButton Auto

Specifies automatic position of the chart.

The Placement group allows you to specify the chart position relative to the data:

RadioButton Bottom

RadioButton Right

Use the Left and Top spinner controls to specify the spacing between the chart and data at the left and at the top respectively.

Use the Height and Width spinner controls to specify the chart height and width respectively.

RadioButton Custom

Specifies absolute position of the chart (irrelative to the data). Use the spinner controls to set the coordinates you need.

Export Data - Format-specific options - Excel - Extensions - Charts - Position

The Category Labels tab allows you to specify in which rows and columns the chart will be built.

RadioButton Column

Use the drop-down list to select the column that will be used to take values for x-axis.

RadioButton Custom

Specify the range of cells from which x-axis values will be taken. Use the spinner controls to set the range you need.

Export Data - Format-specific options - Excel - Extensions - Charts - Category Labels

To build a chart, you also need to create series that will be used to take values for y-axis. To add series for the chart:

  • add one or more series using the iconPlus button;
  • enter the titles;
  • set data ranges (select a column from the drop-down list or set the custom range);
  • define colors for all the graphs.

Use the Title box to specify the series name.

Data range

RadioButton Column

Use the drop-down list to select the column that will be used to take values for the series.

RadioButton Custom

Specify the range of cells from which the series will be formed. Use the spinner controls to set the range you need.

Press the [image] button to set the color for the series.

Export Data - Format-specific options - Excel - Extensions - Series


Cells

If you need to add a value in a specific cell:

  • set the cell coordinates (Col and Row);
  • select the cell type;
  • enter a value;
  • if you are adding a numeric or a date/time value, you can set the cell format;
  • set the font, borders and fill properties using the corresponding tabs.

Export Data - Format-specific options - Excel - Extensions - Cells

The Base tab allows you to specify basic properties of the cell.

Use the Col and Row spinner controls to specify the column and row denoting the cell.

Use the Cell type drop-down list to select the data type for the cell (Boolean, DateTime, Numeric or String).

Set the required value in the Value edit box.

The Formats group allows you to specify data format for numeric or a date/time types.

The font, borders and fill options are specified in the same way as for output Columns. For details refer to the Columns page.


Merged Cells

If you want to merge two or more cells, set the range of cell coordinates: First col, Last col, First row, Last row. Use the spinner controls to set the range you need.

Export Data - Format-specific options - Excel - Extensions - Merged Cells


Advanced

The Advanced tab allows you to set a number of advanced options to be applied to the result MS Excel file.

Page header

If necessary, enter some text for the page header.

Page footer

If necessary, enter some text for the page footer.

Hint: It is also possible to set macros in the Page header and Page footer fields:

&N stands for the quantity of pages;

&P - the number of the current page.

Sheet title

Specify the sheet title for the target file.

Page background

If necessary, use the Ellipsis EllipsisButton button to browse for a graphical file to be applied as the page background.

Export Data - Format-specific options - Excel - Advanced

CheckBox Calculate column width automatically

This option allows the wizard to determine column width in the target file automatically according to column size.


Access options

This step allows you to set options for the target MS Access (*.mdb, *.accdb) file.

Set the name for the target table and specify whether the wizard should create a new table in the MS Access database if it does not exist yet, or use the existing table to export data into.

Export Data - Format-specific options - Access

When you are done, click the Next button to proceed to Setting common export options.


RTF options

This step allows you to set options for the target Rich Text Format (*.rtf) files.

  • Base Styles
  • Strip Styles

For your convenience the previews illustrating the changes are displayed in the Sample Group area within the Base Styles and the Strip Styles tabs.

Export Data - Format-specific options - Word

When you are done, click the Next button to proceed to Setting common export options.


Base Styles

The Base Styles tab contains the list of target file entities: HEADER, CAPTION, DATA, FOOTER. You can customize style options, such as font and size, background and foreground colors, text alignment, etc. for each of them by clicking the corresponding item in the list and setting the options in the right-side panel. You can also switch page orientation for the target Word/RTF file using this tab.

Export Data - Format-specific options - Word - Base Styles

Use the Font and Size drop-down lists to select the font and size to be applied to the text.

Use the buttons below to set font color, make text bold, italicized, underlined, strikethrough text, specify horizontal align.

CheckBox Highlight

Enables/disables text highlight.

CheckBox Background

Enables/disables background for text.

Press the [image] button to set the background color for the text.

Press the [image] button to set the highlight color for the text.

You can reset the changes any time using the Reset Item and the Reset All buttons.


Strip Styles

Using the Strip Styles tab you can create a style template: set font, size, background and foreground colors, text alignment, highlight and save them.

To add a style template, click the Plus iconPlus button.

To delete a style template, select it and click the Minus iconMinus button.

To reorder style templates in the list, use the btnMoveItemUp btnMoveItemDown buttons.

To load a style template, click the iconLoadFromFile button.

To save the current style template, click the btnSave button.

If you have created or loaded more than one style template, they can be ignored, or used column-by-column or row-by-row (it depends on the Strip type selection).

Export Data - Format-specific options - Word - Strip Styles

You can reset the changes any time using the Reset Item and the Reset All buttons.


HTML options

This step allows you to set options for the target HTML (*.html) file.

  • Preview
  • Basic
  • Multi-file
  • Advanced

Export Data - Format-specific options - HTML

When you are done, click the Next button to proceed to Setting common export options.


Preview

The Preview tab allows you to customize the style that will be applied to the target HTML file using a number of built-in templates provided in the Templates drop-down list.

Export Data - Format-specific options - HTML - Preview

You can select any of the pre-defined templates and customize it by clicking objects in the preview panel, and save the settings as a custom template using the Save template... button. Use the Load template... button to load a previously saved custom template from your hard disk.

Click on an element of the table to select the color that will be applied for this element (background, font, header row, odd row, even row, non-visited link, visited link, active link).


Basic

The Basic tab allows you to specify the basic parameters of target HTML file:

  • specify the title of the result file;
  • select whether the cascade style sheet (CSS) should be internal or external (the Ellipsis EllipsisButton button to browse for a *.css file);
  • determine whether boolean columns of the table should be exported as HTML check boxes.

Export Data - Format-specific options - HTML - Basic


Multi-file

The Multi-file tab provides you with an ability to split the target HTML file into several separate files. This tab allows you to specify the record count for a single file, set an option to generate an index HTML file, and add an ability to navigate between the exported files.

Export Data - Format-specific options - HTML - Multi-file

Multi-file export

CheckBox Use multi-file export

Enables/disables the multi-file export feature.

Record(s) in a single file

Use the spinner controls to specify the number of records to be exported into each of the files.

CheckBox Generate index

Specifies that an index file containing links to all the data files will be generated. Use the edit-box next to the checkbox to set a name for the index file.

Navigation

This group allows you to specify properties for navigation elements, i.e. the elements that provide quick access to pages of the multi-file document. Navigation is implemented as a set of hyperlinks.

CheckBox On top

Specifies that the hyperlinks will be placed at the top of the page.

CheckBox On bottom

Specifies that the hyperlinks will be placed at the bottom of the page.

Use the Index link, First link, Prior link, Next link and Last link boxes to specify captions for the corresponding navigation elements.


Advanced

The Advanced tab allows you to set a number of advanced options to be applied to the result HTML file.

Export Data - Format-specific options - HTML - Advanced

Body options

Default font

Use the drop-down list to select the font that will be used in the result file by default.

Background

If necessary, use the Ellipsis EllipsisButton button to browse for a graphical file to be applied as the page background.

Table options

Use the spinner controls to specify common table options: cell padding, cell spacing, border.

Background

If necessary, use the Ellipsis EllipsisButton button to browse for a graphical file to be applied as the table background.

It is also possible to define advanced attributes for both the HTML body and table.


PDF options

This step allows you to set options for the target PDF (*.pdf) file.

Fonts

This group of options allows you to customize fonts for the header, caption, data, footer of the result file.

Use the Base font name and Font encoding drop-down lists to select the preferable font (Helvetica, Courier, Times Roman, etc.) and encoding (Standard, WinANSI, MacRoman, PDFDoc) respectively, and the Font size spinner control to specify the font size.

Click the Font color... button to select the color to be applied to the font.

For your convenience the preview illustrating the changes is displayed in the Sample area.

Export Data - Format-specific options - PDF

Page options

Use the Page size drop-down list to select one of the standard page formats (Letter, Legal, A3, A4, etc.).

Use the Width and Height spinner controls to specify the page width and height respectively.

Use the Units drop-down list to select the unit of measure that will be used in report settings: inches, millimeters, or dots.

Use the Orientation drop-down list to select the preferable page orientation: portrait or landscape.

Margins

Use the Left, Right, Top, Bottom spinner controls to specify the corresponding page margins for the output PDF file.

Grid options

Use the Col spacing, Row spacing, Line width spinner controls to specify spacing for grid columns, rows, and grid line width respectively.

When you are done, click the Next button to proceed to Setting common export options.


TXT options

This step allows you to set options for the target text (*.txt) file.

Set the Calculate column width option on if you want each column of the target file to be adjusted to the maximum number of characters in it. The Spacing option specifies the number of spaces between columns in the target file.

Export Data - Format-specific options - TXT

When you are done, click the Next button to proceed to Setting common export options.


CSV options

This step allows you to set options for the target CSV (*.csv) file.

CheckBox Quote strings

Check this option to apply quoting for string values in the target file.

Specify the column separator using the Comma drop-down list and the preferable quote character using the Quote drop-down list.

Export Data - Format-specific options - CSV

When you are done, click the Next button to proceed to Setting common export options.


XML options

This step allows you to set options for the target XML (*.xml) file.

Specify XML document encoding in the Encoding edit box and set the Standalone option on if you intend to create a standalone XML document (standalone="yes").

XML type

Select the type of the result XML document: Datapacket 2.0 or Access.

Conversion between generic XML documents and documents of the XML-Datapacket (CDS) format can be performed with the help of XML Mapper by Borland®.

Export Data - Format-specific options - XML

When you are done, click the Next button to proceed to Setting common export options.


MS Excel / ODS options

This step allows you to set options for the target MS Excel (*.xlsx) or ODF Spreadsheets (*.ods) file.

Using the Base Styles tab you can set font and border options for all elements of the Excel / ODS sheet (HEADER, CAPTION, DATA, FOOTER). You can customize style options, such as font and size, background and foreground colors, text alignment, etc. for each of them by clicking the corresponding item in the list and setting the options in the right-side panel.

If necessary, you can also specify the sheet name for the target Excel / ODS file.

Use the Font and Size drop-down lists to select the font and size to be applied to the text.

Use the buttons below to set font color, make text bold, italicized, underlined, specify horizontal and vertical align.

CheckBox Background

Enables/disables background for text.

Press the [image] button to set the background color for the text.

Press the Wrap Text button to enable/disable the text wrapping feature.

CheckBox Use border

Select border location

For your convenience the previews illustrating the changes are displayed in the Sample Group area within the Base Styles and the Strip Styles tabs.

Export Data - Format-specific options - Excel 2007 - Base Styles

Using the Strip Styles tab you can create a style template: set font, size, background color, text alignment, wrap text options and save them.

To add a style template, click the Plus iconPlus button.

To delete a style template, select it and click the Minus iconMinus button.

To reorder style templates in the list, use the btnMoveItemUp btnMoveItemDown buttons.

To load a style template, click the iconLoadFromFile button.

To save the current style template, click the btnSave button.

If you have created or loaded more than one style template, they can be ignored, or used column-by-column or row-by-row (it depends on the Strip type selection).

Export Data - Format-specific options - Excel 2007 - Strip Styles

You can reset the changes any time using the Reset Item and the Reset All buttons.

The Border tab allows you to specify properties of the borders of the output Excel / ODS file cells.

CheckBox Use border

Enables/disables borders in the output file.

Press the [image] button to set the color to be applied to the borders.

Use the Border Style drop-down list to select the preferable style that will be used for borders (thin, dashed, dashdot, dotted, etc.).

Export Data - Format-specific options - Excel 2007 - Border

When you are done, click the Next button to proceed to Setting common export options.


MS Word / ODT options

This step allows you to set options for the target MS Word (*.docx) or ODF text (*.odt) file.

Using the Base Styles tab you can set font options for all elements of the Word / ODT document (HEADER, CAPTION, DATA, FOOTER). You can customize style options, such as font and size, background and foreground colors, text alignment, text highlight, etc. for each of them by clicking the corresponding item in the list and setting the options in the right-side panel.

Use the Font and Size drop-down lists to select the font and size to be applied to the text.

Use the buttons below to set font color, make text bold, italicized, underlined, strikethrough text, specify horizontal align.

CheckBox Background

Enables/disables background for text.

Press the [image] button to set the background color for the text.

CheckBox Highlight

Enables/disables text highlight.

If this option is enabled, you should select the preferable highlight color from the drop-down list.

For your convenience the previews illustrating the changes are displayed in the Sample Group area within the Base Styles and the Strip Styles tabs.

Export Data - Format-specific options - Word 2007 - Base Styles

Using the Strip Styles tab you can create a style template: set font, size, background color, text alignment, highlight options and save them.

To add a style template, click the Plus iconPlus button.

To delete a style template, select it and click the Minus iconMinus button.

To reorder style templates in the list, use the btnMoveItemUp btnMoveItemDown buttons.

To load a style template, click the iconLoadFromFile button.

To save the current style template, click the btnSave button.

If you have created or loaded more than one style template, they can be ignored, or used column-by-column or row-by-row (it depends on the Strip type selection).

Export Data - Format-specific options - Word 2007 - Strip Styles

You can reset the changes any time using the Reset Item and the Reset All buttons.

Using the Border tab you can enable borders in the result Word 2007 / ODT document and customize them.

CheckBox Use border

Enables/disables borders in the output file.

Press the [image] button to set the color to be applied to the borders.

Use the Border Style drop-down list to select the preferable style that will be used for borders (single, thick, double, hairline, etc.).

Export Data - Format-specific options - Word 2007 - Border

When you are done, click the Next button to proceed to Setting common export options.


Setting common export options

Use this step of the wizard to set common export options. The detailed description of these options is given below.

Export Data - Setting common export options

Constraints

CheckBox Export empty tables

If checked, you can export the table even if it does not contain any data.

Skip ... record(s)

Specifies the number of records to be skipped before export starts.

RadioButton Export all records

Specifies that all records of the table will be exported.

RadioButton Export only ... record(s)

Specifies the number of records to be exported.

CheckBox Open files after export

If this option is checked, the result file will be opened with the currently associated program after the export operation is completed.

CheckBox Print files after export

If this option is checked, the result file will be sent to the default printer after the export operation is completed.

When you are done, click the Next button to proceed to the last step of the wizard.


Exporting data

This step of the wizard is intended to inform you that all export options have been set, and you can start the export process.

The log area allows you to view the log of operations and errors (if any).

Export Data - Exporting data

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the export process is completed.

If necessary, you can save a template for future use.

Click the Finish button to run the export process.

After the operation is completed, you can view the number of exported records, elapsed time, estimated export speed, and the log of operations and errors (if any).


Import Data Wizard

Import Data Wizard allows you to import data to a table / view from any of supported formats (MS Excel, MS Access, DBF, XML, TXT, CSV, HTML, ODF). You can save your settings as a template any time for future use.

To start the wizard, right-click the table/view in DB Explorer, select the Data Manipulation | [image] Import Data... context menu item.

Alternatively, you can open the Data tab of Table Editor / View Editor, right-click the grid there, then select the Data Manipulation | [image] Import Data to <object_name>... context menu item.

  • Setting source file name and format
  • Selecting the source to import data from
  • Setting correspondence between the source and target columns
  • Adjusting common data formats
  • Setting advanced column formats
  • Setting import mode and data write type
  • Customizing common import options
  • Importing data

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Export Data Wizard

Export as SQL Script

Save Data Wizard

Load Data Wizard

Using templates


Selecting source file name and format

This step of the wizard allows you to select the source file format you need to import data from.

Import type

Specify the format of the source file. For details refer to Supported file formats.

Import Data - Selecting source file name and format

Source file name

Type in or use the ExplorerButton button to specify the path to the file using the Open file... dialog. The file name extension changes automatically according to the selected Import Type.

CSV format parameters

For CSV import you should define Delimiter and Quote settings using the corresponding drop-down lists.

Click the Next button to proceed to the Setting columns correspondence step or to the Selecting data source step of the wizard if you have selected MS Access as the source file format.


Selecting data source

This step of the wizard is only available when you are importing data from MS Access. Select a table from the table list or input a query in the corresponding text boxes to specify the data source.

If you choose a query as the data source, you also can load a SQL query from a *.sql file or save the current query text to a file using the Load from File... and the Save to File... buttons correspondingly.

Import Data - Selecting data source

Click the Next button to proceed to the Setting columns correspondence step of the wizard.


Setting columns correspondence

This step of the wizard allows you to set correspondence between columns of the source file and columns of the target PostgreSQL table.

  • MS Excel 97-2003
  • MS Access, DBF, XML Datapacket
  • TXT
  • CSV
  • HTML
  • XML Generic
  • MS Excel/Word, ODF

To get more information about the file formats, see the Supported file formats page.


Excel 97-2003

Specify ranges in the grid for the target and source columns:

  • select a column of the target PostgreSQL table in the Columns list;
  • proceed to the Sheet grid: click a column caption to select the whole column or click the row number to select the whole row;
  • the selected column/row of the source file gets green highlight, and a new range indicating the source and target columns correspondence appears in the Ranges list;
  • repeat the operation for all the columns you need to be included in the import process.

If the source Excel file and the destination PostgreSQL table have the same order of columns or rows, you can use the iconAutoFillColumns Auto Fill Cols or the iconAutoFillRows Auto Fill Rows buttons to set correspondence between them automatically.

If necessary, you can choose to skip a defined number of the source file columns and/or rows using the Col(s) and Row(s) spinner controls of the Skip group (e.g. if you need to exclude column headers from the imported data range).

Import Data - Setting fields correspondence - Excel

To clear ranges for a column, select the column in the Columns list and press the iconCross Clear Ranges button.

To clear all ranges specified for the target table columns, press the iconClearAllRanges Clear All button.

Right-click a range in the Ranges list to call its popup menu. Using the popup menu you can add or edit ranges manually, remove them or change their order.

Import Data - Setting fields correspondence - Excel - Popup menu

The Range dialog allows you to edit the data range for import manually.

Range Type

Use the drop-down list to select whether a column, a row, or a cell of the source Excel file will be mapped to the target table column.

Depending on the selected range type you should specify the column (e.g. B), the row (e.g. 2) or the cell (e.g. A2).

Start / Finish

These groups allow you to set the precise data range for import: select Where data started / finished or use the spinner control to specify the start/finish row (or start/finish column).

Direction

Use this group to select the direction for importing data of the specified range: Down or Up.

Sheet

Use this group to define whether the specified range will be taken from the default Excel sheet or from a custom sheet (select sheet number or sheet name using the corresponding drop-down lists).

Import Data - Setting fields correspondence - Excel - Range

Click the Next button to proceed to the Adjusting data formats step of the wizard.


Access, DBF, XML Datapacket

Set correspondence between the source MS Access columns and the target PostgreSQL table columns:

  • select a column of the target PostgreSQL table in the Destination Columns list;
  • select the corresponding column of the source MS Access table in the Source Columns list;
  • click the iconPlus Add button to set correspondence between the selected columns;
  • the pair of columns appears in the list below;
  • repeat the operation for all the columns you need to be included in the import process.

Use the iconAutoFillColumns Auto Fill button to set correspondence between the source and target columns automatically on the basis of their order.

Import Data - Setting fields correspondence - Access

To remove a correspondence, select the pair of columns in the list below and press the iconMinus Remove button.

To remove all correspondences, press the iconCross Clear button.

Click the Next button to proceed to the Adjusting data formats step of the wizard.


TXT

Set correspondence between the source text file columns and the target PostgreSQL table columns:

  • select a column of the target PostgreSQL table in the Columns list;
  • double-click in the text viewer area to add vertical separators delimiting the source column bounds;
  • click the area between the separators to assign the column to the selected target table column - the selected source column gets black highlight;
  • repeat the operation for all the columns you need to be included in the import process.

If necessary, you can choose to skip a defined number of the source file lines using the Skip Lines spinner control (e.g. if you need to exclude column headers from the imported data range).

Import Data - Setting fields correspondence - TXT

To clear all correspondences, press the iconCross Clear button.

Note: if you cannot see the content of the source text file properly, you should select the appropriate Charset to be used for processing data.

Click the Next button to proceed to the Adjusting data formats step of the wizard.


CSV

Set correspondence between the target table columns and the source CSV file columns:

  • select a column of the target PostgreSQL table in the Columns list;
  • proceed to the source grid viewer area: click a caption to assign the column to the selected target table column;
  • the selected column of the source file gets gray highlight;
  • repeat the operation for all the columns you need to be included in the import process.

If the source CSV file and the destination PostgreSQL table have the same order of columns, you can use the iconAutoFillColumns Auto Fill button to set correspondence between them automatically.

Note that the CSV delimiter is specified at the Selecting source file name and format step of the wizard.

The Col(s) control indicates the currently selected source file column. You can also use this spinner control for quick column selection.

If necessary, you can choose to skip a defined number of the source file rows using the Row(s) spinner control of the Skip group (e.g. if you need to exclude column headers from the imported data range).

Import Data - Setting fields correspondence - CSV

To remove a correspondence, select the column in the Columns list and press the iconCross Clear button.

Note: if you cannot see the content of the source text file properly, you should select the appropriate Charset to be used for processing data.

Click the Next button to proceed to the Adjusting data formats step of the wizard.


HTML

Set correspondence between the target table columns and the source HTML file columns:

  • select a column of the target PostgreSQL table in the Columns list;
  • proceed to the source grid viewer area: select the Table from which you intend to import data and click a column to assign the column to the selected target table column;
  • the selected column of the source file gets gray highlight;
  • repeat the operation for all the columns you need to be included in the import process.

If the source HTML file and the destination PostgreSQL table have the same order of columns, you can use the iconAutoFillColumns Auto Fill button to set correspondence between them automatically.

The Col control indicates the currently selected source file column. You can also use this spinner control for quick column selection.

If necessary, you can choose to skip a defined number of the source file rows using the Row spinner control of the Skip group (e.g. if you need to exclude column headers from the imported data range).

Import Data - Setting fields correspondence - HTML

To remove a correspondence, select the column in the Columns list and press the iconCross Clear button.

To remove all correspondences, press the iconClearAllRanges Clear All button.

Click the Next button to proceed to the Adjusting data formats step of the wizard.


XML Generic

In order to set mapping of a Generic XML document, you should enter the relative XPath (the path must be specified in the XPath format). Press the iconAutoFillColumns Fill Grid button to get the grid filled with text and attribute values of the selected node.

Note: if the source XML document contains huge amount of data, building the tree may take a long time.

Set correspondence between the source XML file columns and the target PostgreSQL table columns:

  • select a column of the target PostgreSQL table in the Columns list;
  • proceed to the source grid viewer area: click a column to assign the column to the selected target table column;
  • the selected column of the source file gets gray highlight;
  • repeat the operation for all the columns you need to be included in the import process.

You can use the iconAutoFillColumns Auto Fill button to set correspondence between the source and target columns automatically according to their order (mapping is started from the first attribute value in this case).

The Col(s) control indicates the currently selected source file column. You can also use this spinner control for quick column selection.

If necessary, you can choose to skip a defined number of the source file lines using the Row(s) spinner control of the Skip group (e.g. if you need to exclude node headers from the imported data range).

Import Data - Setting fields correspondence - XML Document

To remove a correspondence, select the column in the Columns list and press the iconCross Clear button.

To remove all correspondences, press the iconClearAllRanges Clear All button.

Click the Next button to proceed to the Adjusting data formats step of the wizard.


MS Excel/Word, ODF

Specify ranges in the grid for the target and source columns:

  • select a column of the target PostgreSQL table in the Columns list;
  • proceed to the Sheet grid: click a column to assign the source column to the selected target table column;
  • the selected column of the source file gets gray highlight;
  • repeat the operation for all the columns you need to be included in the import process.

If the source file and the destination PostgreSQL table have the same order of columns, you can use the iconAutoFillColumns Auto Fill button to set correspondence between them automatically.

The Col control indicates the currently selected source file column. You can also use this control for quick column selection.

If necessary, you can choose to skip a defined number of the source file rows using the Skip spinner control (e.g. if you need to exclude column headers from the imported data range).

Import Data - Setting fields correspondence - MS Excel and Word 2007, ODF

To remove a correspondence, select the column in the Columns list and press the iconCross Clear button.

To remove all correspondences, press the iconClearAllRanges Clear All button.

Click the Next button to proceed to the Adjusting data formats step of the wizard.


Adjusting data formats

This step of the wizard provides a number of options for setting common formats for all imported data:

Date & Time formats: Short date, Long date, Short time, Long time;

Separators: Decimal, Thousand, Date, Time;

Boolean True (specify the text that will be displayed for the boolean TRUE values);

Boolean False (specify the text that will be displayed for the boolean FALSE values);

NULL values (specify the text that will be displayed for the NULL values).

For more information refer to the Format specifiers page.

Import Data - Adjusting data formats

Click the Next button to proceed to the Setting advanced column formats step of the wizard.


Setting advanced column formats

This step of the wizard allows you to set formats each column separately.

Select a column in the list and adjust format options that will be applied to this column only.

Import Data - Setting advanced field formats

Specify Generator value and Generator step for incremental data generation into the specified column, or enter a Constant value which will be set for all records in the column.

Specify the NULL value which will be used for the records where the value is NULL.

If necessary, specify the default value.

Use the Left / Right quotation edit boxes to specify left/right quotation marks.

Use the Quotation action drop-down list to select whether the quotation marks should be added, removed, or left 'As is'.

Use the Character case drop-down list to select the case that will be used for string values of the column: Upper, Lower, UpperFirst, UpperFirstWord, or 'As is'.

Use the Character set drop-down list to select which charset will be used for string data in the column: ANSI, OEM, or As is.

The Replacements area allows you to set the text you need to be replaced during data import into the selected column. Press the iconPlus Plus button to specify a new replacement options using the Add Replacement dialog.

Import Data - Setting advanced field formats - Add Replacement

To edit a replacement, click the [image] Edit button.

To remove a replacement, click the iconMinus Minus button.

When you are done, click the Next button to proceed to the Setting import mode step of the wizard.


Setting import mode

This step of the wizard allows you to define the records processing mode as Insert All, Insert New, Update, Update or Insert, Delete, Delete or Insert mode.

Import mode

  • Insert all: all records from the source file are inserted into the tables irrespective of whether any records exist in the destination table or not
  • Insert new: already existing records are skipped, and new records are inserted into the destination table
  • Update: all existing records are updated from the source file
  • Update or insert: already existing records are updated and new records are inserted into the destination table
  • Delete: already existing records are deleted
  • Delete or insert: existing records are deleted and new records are inserted into the destination table

Import Data - Setting import mode

Here is an example of some import modes offered by Import Data Wizard:

All import modes (except for the Insert All mode) are based on key values information. In order to perform import operations with these modes used, you need to have matches between the source file key column(s) and the destination table key column(s).

For example, your source file contains three rows with the key values 1, 2, 3, and your destination table contains three rows with the key values 1, 2, 4.

Destination table | Source file data
Import Data - Setting import mode - Destination Table | Import Data - Setting import mode - Source Table

If you use the Insert new import mode, in this case only the row with key value 3 will be inserted into the destination table.

If you use the Update import mode, then the rows with key values 1, 2 will be updated.

If you use the Update or insert import mode, then rows 1, 2 will be updated and the row with key value 3 will be inserted.

It is applied to all other import modes, except for the Insert all mode. For all these modes (except for the Insert all mode) it is obligatory to select the primary key columns. This column (or columns) is used as key column to identify specific data in the target database.

Insert new | Update | Update or insert | Delete | Delete or insert
Import Data - Setting import mode - Result - Insert new | Import Data - Setting import mode - Result - Update | Import Data - Setting import mode - Result - Update or insert | Import Data - Setting import mode - Result - Delete | Import Data - Setting import mode - Result - Delete or insert

The key columns for these operations are defined in the Key columns area.

Import type

Single commands / Universal mode / Batch insert type

The Single commands import mode is performed with the Single Commands method used and serves to generate and execute single SQL commands on the server, whereas the Batch insert mode uses native PostgreSQL commands to import a data set as a batch. With the help of the Single commands import mode your data can be imported considerably faster as compared to the Universal mode which is used for backward compatibility.

Use Import mode to select whether to insert all records, or to update/delete existing ones. Note that for updating/deleting existing records in the target table you should move its key columns from the Available columns list to the Selected columns list.

Key columns

The area allows you to select the columns of the table to be used as the key columns for the import process.

To select a column, you need to move it from the Available columns list to the Selected columns list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the columns from one list to another.

When you are done, click the Next button to proceed to the Customizing common options step of the wizard.


Customizing common options

Use this step of the wizard to set common import options. The detailed description of these options is given below.

Import Data - Customizing common options

Commit

RadioButton Commit when done

Commits the transaction when all records are imported.

RadioButton Commit after each block

Inserts the COMMIT statement after a defined number of records.

RadioButton Commit changes manually

Select this option if you intend to commit the transaction manually.

Block size

Use the spinner control to define the number of records in each committed block.

Record count

RadioButton Import all records

Specifies that all records of the source file will be imported.

RadioButton Import only ... record(s)

Specifies the number of records to be imported.

When you are done, click the Next button to proceed to the last step of the wizard.


Importing data

This step of the wizard is intended to inform you that all import options have been set, and you can start the import process.

The log area allows you to view the log of operations and errors (if any).

Import Data - Importing data

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the import process is completed.

If necessary, you can save a template for future use.

Click the Run button to run the import process.

After the operation is completed, you can view the total number of processed records, the number of inserted/updated/deleted records, the number of committed records, the number of errors, elapsed time, and the log of operations and errors (if any).


Export as SQL Script

SQL Manager for PostgreSQL
  • Index
  • « Prev
  • Next »

Export as SQL Script Wizard

Export as SQL Script Wizard allows you to export data from a table / view or from a query result to SQL script as a number of INSERT statements. You can save your settings as a template any time for future use.

To start the wizard, right-click the object in DB Explorer, select the Data Manipulation | [image] Export Data as SQL Script...context menu item.

Alternatively, you can open the Data tab of Table Editor / View Editor or the Result(s) tab of Query Data / Design Query, right-click the grid there, then select the Data Manipulation | [image] Export <object_name> as SQL Script... context menu item.

  • Selecting destination DBMS
  • Setting destination file name
  • Setting BLOB options
  • Selecting column to export
  • Editing the result table definition
  • Setting export options
  • Exporting as SQL Script

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Export Data Wizard

Import Data Wizard

Save Data Wizard

Load Data Wizard

Using templates


Selecting destination DBMS

This step of the wizard allows you to define the destination server you need to export data for. The result script will be generated in compliance with the specifications of the selected DBMS:

RadioButton DB2

RadioButton InterBase/Firebird

RadioButton Microsoft® SQL Server™

RadioButton MySQL

RadioButton Oracle

RadioButton PostgreSQL

Export as SQL Script - Defining type of destination server

CheckBox Add CREATE TABLE statement

Check this option to add the CREATE TABLE statement to the result script.

Click the Next button to proceed to the Setting destination file name step of the wizard.


Setting destination file name

Specify whether the result script will be loaded to Execute Script Editor or saved to a file.

File name

Type in or use the btnSaveAs button to specify the path to the file and the file name.

If necessary, select the File charset using the corresponding drop-down list.

Enter the Table name and the Schema name to be included in the result SQL script. Schema name should only be specified for the DBMS in which this object is implemented.

Export as SQL Script - Setting destination file name

Click the Next button to proceed to the Setting BLOB options step of the wizard.


Setting BLOB options

BLOB and arrays options

In this group of options you can determine processing BLOB values.

RadioButton Don't extract BLOB fields

BLOB values are not extracted in the script

RadioButton Extract BLOB fields as strings

BLOB values are extracted as strings

Export as SQL Script - Setting BLOB options

Click the Next button to proceed to the Selecting columns to export step of the wizard.


Selecting column to export

This step of the wizard allows you to select the table column(s) to be exported to SQL script.

To select a column, you need to move it from the Available columns list to the Selected columns list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the columns from one list to another.

Export as SQL Script - Selecting fields to export

Click the Next button to proceed to the Editing table definition step of the wizard.


Setting export options

Specify common export options according to your needs.

If necessary, you can choose to replace non-print characters in strings with spaces.

CheckBox Quote identifiers

Check this option to apply quoting for identifiers in the destination file.

CheckBox Use multi insert statements

Check this option to group insert statements.

Data options

Records in block

Use the spinner control to define the number of records in each committed block.

CheckBox Insert COMMIT after each block

Check this option to add the COMMIT statement after a defined number of records.

Export as SQL Script - Setting export options

Click the Next button to proceed to Exporting as SQL Script.


Editing table definition

This step is available only if the Add CREATE TABLE statement option was checked on the Selecting destination DBMS step of the wizard. It allows you to view/edit the SQL script for creating the table.

For your convenience the syntax highlight, code folding and a number of other features for efficient SQL editing are implemented. For details see Working with Query Data area and Using the context menu.

Export as SQL Script - Editing table definition

Click the Next button to proceed to the Setting export options step of the wizard.


Exporting as SQL Script

This step of the wizard is intended to inform you that all export options have been set, and you can start the export as SQL script process.

The Operations tab allows you to view the log of operations and errors (if any).

Export as SQL Script - Exporting as SQL Script

CheckBox Load generated script into Script Editor

Check this option to load the result script to Execute Script Editor.

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the export process is completed.

If necessary, you can save a template for future use.

Click the Run button to run the export as SQL script process.


Save Data Wizard

Save Data Wizard allows you to use the COPY PostgreSQL statement to copy the contents of a table (or view / query result - for PostgreSQL server 8.2 and higher) to a file at a very high speed. You can save your settings as a template any time for future use.

To start the wizard, right-click the table in DB Explorer, select the Data Manipulation | [image] Save Data to File on Server... context menu item.

Alternatively, you can open the Data tab of Table Editor / View Editor or the Result(s) tab of Query Data / Design Query, right-click the grid there, then select the Data Manipulation | [image] Save Data to File on Server... context menu item.

  • Setting output file name
  • Selecting columns
  • Specifying type of output file
  • Setting output file parameters
  • Saving data

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Export Data Wizard

Import Data Wizard

Export as SQL Script

Load Data Wizard

Using templates


Setting output file name

This step of the wizard allows you to specify absolute path and name of the output file to save the table data into.

The file must be accessible to the server and the name must be specified from the viewpoint of the server. Note that the file will be written directly by the server, not by the client application. Therefore, it must reside on or be accessible to the database server machine, not the client.

Save Data Wizard - Setting output file name

Click the Next button to proceed to the Selecting columns step of the wizard.


Selecting columns

In this step of the wizard you are to select the table columns from which the data should be saved.

To select a column, you need to move it from the Available columns list to the Selected columns list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the columns from one list to another.

If you need to copy all available columns, you can select the CheckBox All columns option.

Save Data Wizard - Defining columns

Click the Next button to proceed to the Specifying type of output file step of the wizard.


Specifying type of output file

Use this step of the wizard to select the type of the output file:

RadioButton CSV

Specifies CSV as the output file format.

RadioButton Text

Specifies TXT as the output file format.

RadioButton Binary

Causes all data to be stored in binary format rather than as text. You will not need to specify the DELIMITER or NULL options in binary mode.

CheckBox With OIDs

This option specifies copying the OID for each row (an error is raised if this option is enabled for a table that does not have OIDs, or in the case of copying a query).

Save Data Wizard - Specifying type of output file

Click the Next button to proceed to the Setting output file parameters step of the wizard.


Setting output file parameters

Define the output file parameters according to the instructions below.

CSV file parameters

Quote

Specify the quotation character to be used in the CSV file. By default, the double-quote is used.

Escape

Specify the character that should appear before a QUOTE data character value in the CSV file. By default, the same character as for Quote is used (double-quote).

Delimiters

Specify the single character that separates columns within each row (line) of the file. By default, a comma is used.

NULL value

Specify the string that represents a NULL value. You might prefer an empty string for cases where you do not want to distinguish nulls from empty strings.

CheckBox Force quote columns

This option forces quoting to be used for all non-NULL values in each column selected below. NULL output is never quoted.

To select a column, you need to move it from the Available columns list to the Selected columns list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the columns from one list to another.

Save Data Wizard - Setting CSV parameters

Text file parameters

Delimiters

Specify the single character that separates columns within each row (line) of the file. By default, a tab character is used.

NULL value

Specify the string that represents a NULL value. The default is "\N" (backslash-N). You might prefer an empty string for cases where you do not want to distinguish nulls from empty strings.

Save Data Wizard - Setting TXT parameters

When you are done, click the Next button to proceed to the last step of the wizard.


Saving data

This step of the wizard is intended to inform you that all COPY options have been set, and you can start the saving data process itself.

The Operations tab allows you to view the log of operations and errors (if any).

Save Data Wizard - Saving data

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the saving data process is completed.

If necessary, you can save a template for future use.

Click the Run button to run the saving data process.


Load Data Wizard

Load Data Wizard allows you to use the COPY FROM PostgreSQL statement to copy data from a standard file-system file to a table at a very high speed. This command copies data from a file to a table, appending the data to whatever is in the table already. The file must be accessible to the server and the name must be specified from the viewpoint of the server. You can save your settings as a template any time for future use.

To start the wizard, right-click the table in DB Explorer, select the Data Manipulation | [image] Load Data... context menu item.

Alternatively, you can open the Data tab of Table Editor / View Editor, right-click the grid there, then select the Data Manipulation | [image] Load Data... context menu item.

  • Setting input file name
  • Selecting columns
  • Specifying type of input file
  • Specifying input file parameters
  • Loading data

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Export Data Wizard

Import Data Wizard

Export as SQL Script

Save Data Wizard

Using templates


Setting input file name

This step of the wizard allows you to specify absolute path and name of the input file to load data from.

The file must be accessible to the server and the name must be specified from the viewpoint of the server. Note that the file will be read directly by the server, not by the client application. Therefore, it must reside on or be accessible to the database server machine, not the client.

Load Data Wizard - Setting input file name

Click the Next button to proceed to the Selecting columns step of the wizard.


Selecting columns

In this step of the wizard you are to select the columns into which the data should be loaded.

To select a column, you need to move it from the Available columns list to the Selected columns list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the columns from one list to another.

If you need to copy to all available columns, you can select the CheckBox All columns option.

Load Data Wizard - Defining columns

Click the Next button to proceed to the Specifying type of input file step of the wizard.


Specifying type of input file

Use this step of the wizard to select the type of the input file:

RadioButton CSV

Specifies CSV as the input file format.

RadioButton Text

Specifies TXT as the input file format.

RadioButton Binary

Causes all data to be read in binary format rather than as text. You will not need to specify the DELIMITER or NULL options in binary mode.

CheckBox With OIDs

Specifies copying the OID for each row (an error is raised if this option is enabled for a table that does not have OIDs, or in the case of copying a query).

Load Data Wizard - Specifying type of input file

Click the Next button to proceed to the Specifying input file parameters step of the wizard.


Specifying input file parameters

Define the source (input) file parameters according to the instructions below.

CSV file parameters

Quote

Specify the quotation character used in the CSV file. By default, the double-quote is used.

Escape

Specify the character that appears before a QUOTE data character value in the CSV file. By default, the same character as for Quote is used (double-quote).

Delimiters

Specify the single character that separates columns within each row (line) of the file. By default, a comma is used.

NULL value

Specify the string that represents a NULL value. Note that any data item that matches this string will be stored as a null value, so you should make sure that you use the same string as you used with Save Data Wizard.

CheckBox Force not null

If this option is selected, each column selected below will be processed as though it were quoted and hence not a NULL value.

To select a column, you need to move it from the Available columns list to the Selected columns list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the columns from one list to another.

Load Data Wizard - Setting CSV parameters

Text file parameters

Delimiters

Specify the single character that separates columns within each row (line) of the file. By default, a tab character is used.

NULL value

Specify the string that represents a NULL value. The default is "\N" (backslash-N). You might prefer an empty string for cases where you do not want to distinguish nulls from empty strings.

Load Data Wizard - Setting TXT parameters

When you are done, click the Next button to proceed to the last step of the wizard.


Loading data

This step of the wizard is intended to inform you that all COPY FROM options have been set, and you can start the loading data process itself.

The Operations tab allows you to view the log of operations and errors (if any).

Load Data Wizard - Loading data

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the loading data process is completed.

If necessary, you can save a template for future use.

Click the Run button to run the loading data process.


Tools

The following database tools are available in SQL Manager for PostgreSQL:

Dependency Tree

Allows you to view all the object dependencies in one diagram.

Database Designer

Allows you to lay out your database schema visually.

Execute Script Editor

Executes SQL scripts in the database.

Extract Database Wizard

Extracts the table metadata and/or data to an SQL script which can be executed later on another machine to restore the database structure and/or data.

Copy Database Wizard

Allows you to copy database objects and/or data from one database to another.

Print Metadata

Creates powerful metadata reports in the WYSIWYG mode ready for printing.

HTML Report

Creates powerful metadata reports in the HTML format.

Reports management

Tools for efficient management of reports: creating, editing, viewing, printing.

SQL Monitor

Displays all the SQL statements executed while working in SQL Manager for PostgreSQL.

Using templates

Facilitates using SQL Manager wizards.

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Services

Options

How To...


Dependency Tree

The Dependency Tree tool allows you to view all the object dependencies in one diagram.

To call the Dependency Tree window, select the Tools | btnDependencyTree Dependency Tree main menu item, or use the btnDependencyTree Dependency Tree button on the main toolbar.

  • Using Navigation bar and Toolbar
  • Viewing dependency tree

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Database Objects Management


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Dependency Tree.

Dependency Tree - Using Navigation bar

Database

iconDB select a database for browsing object dependencies

General

iconRefresh refresh the currently displayed dependency tree

iconPrint print the diagram

iconPrintSetup set printing options using the Print Setup dialog

iconSaveAsPicture save the current diagram as a picture

iconRestoreDefaultSize restore the default size and position of the window

Object

navigate by switching to the previous object

navigate by switching to the next object

show/hide subobjects

select a root object

Diagram Layout

iconShowAllObjects show all objects

iconShowDependingOnRoot show objects depending on Root

iconShowRootDependsOn show Root depends on objects

NB: You can enable\disable Toolbars and Navigation bars at Environment options.

Hint: Items of the Object pane of the Navigation bar are also available in the context menu of the Dependency Tree area.


Viewing dependency tree

To view dependencies of an object, click the Select object Navigation bar item. Then select the schema and the required object in the Select Object dialog window. The dependency tree will appear in the main area of the window.

Dependency Tree - Select object

While the tree of dependencies is being built, the progress bar is displayed in the status area at the bottom of the window.

The root object is marked out with a blue frame.

The objects that the root object depends on are located to the left of the root object.

The objects that depend on the root object are located to the right of the root object.

Object dependencies are denoted as regular arrows from the left to the right (->).

A cyclic dependency (i.e. when the object already has some other depending object(s)) is denoted as a line ending with a cross (-x).

You can switch between objects by selecting them in the diagram. The selected object becomes the root object. To make an object root, you can also right-click it in the diagram area and select Set as Root from the context menu. The context menu of an object also allows you to edit it using the corresponding editor.

The history of selected root objects is also available: you can move back and forward through this history using the Previous object and the Next object links on the Navigation bar or toolbar.

Hint: To show/hide subobjects (e.g. table triggers, foreign keys), click the Show subobjects / Hide subobjects item on the Navigation bar.

See also:

Select Object dialog


SQL Monitor

SQL Monitor allows you to view the log of all operations performed over databases and database objects in SQL Manager for PostgreSQL. The content of the window is read-only.

To open the SQL Monitor window, select the Tools | [image] SQL Monitor main menu item, or use the Shift+Ctrl+M shortcut.

  • Using Navigation bar and Toolbar
  • Working with SQL Monitor

See also:

SQL Monitor options


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in SQL Monitor.

SQL Monitor - Using Navigation bar

General

clear the content of the window

save the content to a *.txt file using the Save as... dialog

iconFindText search for a string using the Find Text dialog

iconSearchAgain search again

iconOptions configure SQL Monitor using the SQL Monitor section of the Environment Options dialog

iconRestoreDefaultSize restore the default size and position of the window

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Working with SQL Monitor

The working area of SQL Monitor lists the log of database operations and SQL queries as items, each consisting of 3 parts: Executed (the date and time of the operation), Operation (SQL statement sent to the server), Result (the result of the operation).

Items of the context menu of SQL Monitor area provide access to various functions for working with the window content. The context menu contains standard text-processing functions (Copy, Select All), spelling checking and functions for working with the content as a whole, e.g. you can set markers, move the cursor to a particular line, save the content to a file or as a favorite query, configure the editor using the properties item or preview/print the content. Most of these operations can be also performed with the corresponding hot keys used.

SQL Monitor - Working with SQL Monitor

Implementation of the Find Text dialog and Incremental search bar contributes to more efficient work with the content of SQL Monitor.


Execute Script Editor

Using Execute Script editor you can view, edit and execute SQL scripts.

To open the editor select the Tools | Execute Script main menu items or use the corresponding btnShowSQLScript toolbar buttons. You can also use the Shift+Ctrl+S shortcut for the same purpose.

In the script area you can view and edit the SQL script text. For your convenience syntax highlight and code completion features are implemented.

  • Using Navigation bar and Toolbar
  • Working with Execute Script editor area
  • Using Script Explorer
  • Script execution

Note: Execute Script Editor does not show results returned upon SELECT queries execution. Please use Query Data for that purpose instead.

See also:

Query Data

Execute Script options

Editor Options


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Execute Script Editor.

SQL Script Editor - Using Navigation bar

Destination

iconHost select a host

iconDB select a database for the script

General

iconExecute execute the current script

iconCompile execute a script from file

iconNew create a new script

iconLoadFromFile load a script from an *.sql file using the Open SQL Script dialog

iconSaveToFile save the current script

iconSaveToFileAs save the current script as Shared Script using the Save to Shared Scripts as... dialog

iconSaveToFileAs save the script to an *.sql file using the Save as... dialog

iconDBExplorer enable/disable parsing of SQL code

enable/disable result log

enable/disable all code features

iconOptions configure Execute Script Editor within the Script Options section of the Environment Options dialog

iconRestoreDefaultSize restore the default size and position of the editor window

Version Control

This panel is enabled if change management feature is enabled for the database.

Use the drop-down list to define whether to add this transaction to version control log always or only if script changes objects.

RadioButton Ask comment before run

RadioButton Ask comment after run

Explorer

iconDBExplorer browse the tree objects used in the script using the Script Explorer pane

NB: You can enable\disable Toolbars and Navigation bars at Environment options.

See also:

Working with Execute Script editor area

Using Script Explorer

Script execution


Working with Execute Script editor area

The Editor area of Execute Script is provided for efficient working with SQL scripts in text mode.

For your convenience the syntax highlight, code completion and a number of other features for efficient SQL editing are implemented:

  • using object links allowing you to open the object in the associated editor;
  • ability to display line numbers;
  • code folding for statements and clauses;
  • customizable margins and gutters;
  • formatting code for better representation

and more.

The context menu of Execute Script Editor area contains execution commands, most of the standard text-processing functions (Cut, Copy, Paste, Select All), spelling checking and functions for working with the script as a whole, e.g. you can enable/disable parsing, toggle bookmarks and comments, move the cursor to a particular line, change the case of selected text, load/save the content from/to a file or save as a favorite query, configure the editor using the Properties item or preview/print the text of the script. Most of these operations can be also performed with the corresponding hot keys used.

Implementation of the Find Text / Replace Text dialogs and Incremental search bar contributes to more efficient work with the SQL code.

SQL Script Editor - Working with SQL Script editor area

Note: If a database is selected within the navigation bar, but script contains the '\connect to database2' statement (where 'database2' differs from the selected one), then the Reset button appears. Click this button to ignore this statement. Script will be performed for the database selected within the navigation bar.

SQL Script Editor - Reset Script

See also:

Using Navigation bar and Toolbar

Using Script Explorer

Script execution

Managing Favorite queries

Execute Script options


Using Script Explorer

The Explorer group on the Navigation bar displays the tree of objects, used in the current script and allows you to get to the required script fragment quickly by clicking the object in the tree.

SQL Script Editor - Using Script Explorer

Hint: When you click a node in the Script Explorer tree, the corresponding SQL statement is highlighted in the editor area. If you double-click a node, the corresponding SQL statement is highlighted, and the current focus is switched to the editor area (the cursor appears after the highlighted statement).

See also:

Using Navigation bar and Toolbar

Working with Execute Script editor area

Database Objects Management


Script execution

When all the script parameters are set, you can immediately execute the script in Execute Script Editor.

To execute a script, click the btnExecuteQuery Execute script item of the Navigation bar or toolbar. You can also use the context menu or F9 hot key for the same purpose.

SQL Script Editor - Script execution

Note: If the CheckBox Execute selected text separately option (see the Tools | Execute Script section of the Environment Options dialog) is enabled (by default) and a text fragment is currently selected, only this fragment is executed when you click Execute script on the Navigation bar or press F9. If this option is disabled, the whole script is executed, but you can still execute the selected fragment using the corresponding Execute Selected Only item of the context menu or by pressing Ctrl+F9.

If the SQL syntax is correct, the script is executed and the 'Done!' information message appears.

SQL Script Editor - Script execution - Done

If the syntax contains errors or script cannot be executed, the corresponding error message is displayed in the status bar area at the bottom of the editor window.

Hint: When you select an item from the error list (in the status bar area), the corresponding SQL statement is highlighted in the editor area. If you double-click an item, the corresponding SQL statement is highlighted, and the current focus is switched to the editor area (the cursor appears after the highlighted statement).

Note: Execute Script Editor does not show results returned upon SELECT queries execution. Please execute such queries in Query Data to see the result dataset.

See also:

Using Navigation bar and Toolbar

Working with Execute Script editor area

Using Script Explorer


Extract Database

Extract Database Wizard allows you to extract database objects and/or data to an SQL script, e.g. for backup purposes.

To start the wizard, select the Tools | btnExtractDB Extract Database... main menu item, or right-click the database alias in the DB Explorer tree and select the Tasks | btnExtractDB Extract Database... item from the context menu.

  • Selecting a database for extraction
  • Specifying destination file name
  • Setting extraction mode
  • Selecting objects for metadata extraction
  • Selecting objects for data extraction
  • Customizing script options
  • Start of extraction process

See also:

Execute Script Editor

Database Objects Management

Using templates


Selecting source database

This step of the wizard allows you to select the source database from which metadata and/or data are to be extracted.

If necessary, check the CheckBox Extract all metadata and data of the database option to simplify the wizard.

Extract Database - Selecting source database

Click the Next button to proceed to the Specifying destination file name step of the wizard.


Specifying destination file name

Script destination

This group of options allows you to specify whether the result SQL script will be automatically loaded to Execute Script Editor or saved into a file.

File name

Set a name for the result *.sql file and type in or use the btnSaveAs Save as... button to specify the path to this file on your local machine or on a machine in the LAN.

File charset

If necessary, use the drop-down list to select the character set to be applied to the output file.

Extract Database - Specifying destination file name

Depending on whether you have checked the CheckBox Extract all metadata and data of the database option at the Selecting source database step, upon pressing the Next button you will either proceed to the next step of the wizard, or you will be immediately forwarded to the Customizing script options step of the wizard.


Setting extraction mode

This step allows you to specify the extraction mode: choose whether structure only, data only or both are to be extracted.

Extract Database - Setting extraction mode

Click the Next button to proceed to Selecting objects for structure extraction.


Selecting objects for structure extraction

This step of the wizard allows you to select objects for metadata extraction.

Note that this step is only available if the CheckBox Extract all metadata and data of the database option was unchecked when selecting the source database.

RadioButton Extract all objects

Adds all objects of the database to structure extraction process.

RadioButton Extract all objects of schema...

Adds all objects of a schema to structure extraction process.

Schema name

Use the drop-down list to select the schema to extract all objects from.

RadioButton Extract selected objects

Adds only selected objects to structure extraction process.

Objects to extract

Use the drop-down list to select the type of objects to be extracted.

To select an object, you need to move it from the Available list to the Selected list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the objects from one list to another.

Extract Database - Selecting objects for structure extraction

Click the Next button to proceed to Selecting objects for data extraction.


Selecting objects for data extraction

This step of the wizard allows you to select tables for data extraction.

Note that this step is only available if the CheckBox Extract all metadata and data of the database option was unchecked when selecting the source database.

RadioButton Extract all tables

Adds all tables of the database to data extraction process.

RadioButton Extract data of tables selected on the previous step

Adds only the tables selected for metadata extraction.

RadioButton Extract data of selected tables

Adds only selected tables to data extraction process.

To select a table, you need to move it from the Available list to the Selected list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the tables from one list to another.

Extract Database - Selecting objects for data extraction

Click the Next button to proceed to the Customizing script options step of the wizard.


Customizing script options

This step allows you to customize common script options and data options for the extraction process.

Script options

CheckBox Generate DROP statements

Check the option to add the DROP statements for the extracted objects in the result script.

CheckBox With IF statements

Check this option to add the IF keyword to the DROP statements in the result script.

CheckBox CHARACTER and CHARACTER VARYING as CHAR and VARCHAR

This option specifies that the CHARACTER and CHARACTER VARYING columns will be scripted as CHAR and VARCHAR respectively.

CheckBox Add OID into object comments

Enable this option to add object identifier to object comments.

Extract Database - Customizing script options

Data options

Records in a block / CheckBox Insert "COMMIT" statement after each block

These controls allow you to define whether the COMMIT statement is added to the script or not, and to specify the number of records in each block to be supplemented with this statement.

Extract data as

Select the preferable type of extraction statements that will be placed to the result script:

RadioButton Insert statements

RadioButton Copy statements

CheckBox Abort extraction on error

This option determines whether the extraction process should be stopped or forced to continue if an error occurs.

Click the Next button to proceed to the last step of the wizard.


Start of extraction process

This step of the wizard is intended to inform you that all extraction options have been set, and you can start the extraction process.

The Operations tab allows you to view the log of operations and errors (if any).

Extract Database - Start of extraction process

CheckBox Close the wizard after successful completion

If this option is selected, the wizard is closed automatically when the extraction process is completed.

If necessary, you can save a template for future use.

Click the Run button to run the extraction process.


Copy Database

Copy Database Wizard allows you to transfer the entire database with its objects and data from one location to another.

To run the wizard, select the Tools | iconDatabases Copy Database... main menu item, or right-click the database alias in the DB Explorer tree and select the Tasks | iconDatabases Copy Database... item from the context menu.

  • Selecting source database
  • Specifying destination database
  • Selecting components to copy
  • Selecting objects to copy their structure
  • Selecting objects to copy their data
  • Setting additional options
  • Copying database

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.


Selecting source database

This step of the wizard allows you to select the source database to copy and specify destination database registration status.

Copy Database Wizard - Selecting source database

Source Database

Use the drop-down list of registered and currently connected databases to select the database to copy.

Destination database

Select RadioButton Registered database if you want to copy the specified database to a registered database, or select RadioButton Non-registered database to copy the specified database to a new (non-registered) database.

Click the Next button to proceed to the Specifying destination database step of the wizard.


Specifying destination database

Use this step of the wizard to set the destination database for copying objects to. If the database is already registered (i.e. RadioButton Registered database was selected at the previous step), then you just need to select a host and a database that resides on this host. Otherwise you should set all the connection properties using the corresponding boxes and options: Host name, Port, User name, Password, Database name.

Copy Database Wizard - Specifying destination database

Specify the host where the destination database resides: type in the host name in the Host name field or select one in the drop-down list.

Enter PostgreSQL port to connect through in the Port field and provide authorization settings: User name and Password.

Database

Type in the name of the database to copy objects into.

If necessary, check the CheckBox Create new database option to create a new database for copying objects.

Check the CheckBox Register destination database after execution option to register the newly created database in SQL Manager (the Database Registration Info dialog will be opened after database creation).

Click the Next button to proceed to the Selecting components to copy step of the wizard.


Selecting components to copy

This step allows you to specify the components to copy: choose whether structure only, data only or both structure and data should be copied.

Copy Database Wizard - Selecting components to copy

Click the Next button to proceed to the Selecting objects to copy their structure step of the wizard, or to the Selecting objects to copy their data step if you have specified to copy data only.


Selecting objects to copy their structure

This step of the wizard allows you to select objects for copying metadata.

Note that this step is only available if the RadioButton Copy both structure and data or RadioButton Copy structure only mode was specified when Selecting components to copy.

RadioButton Copy all objects

Adds all objects of the source database to the Copy Database process.

RadioButton Copy all objects of schema...

Adds all objects of a schema to the Copy Database process.

Schema name

Use the drop-down list to select the schema to copy all objects from.

RadioButton Copy selected objects

Adds only selected objects to the Copy Database process.

Objects to copy

Use the drop-down list to select the type of objects to be copied.

To select an object, you need to move it from the Available list to the Selected list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the objects from one list to another.

Copy Database Wizard - Selecting objects to copy their structure

Click the Next button to proceed to the Selecting objects to copy their data step of the wizard, or to the Setting additional options step if you specified to copy structure only when Selecting components to copy.


Selecting objects to copy their data

This step of the wizard allows you to select tables for copying data.

Note that this step is only available if the RadioButton Copy both structure and data or RadioButton Copy data only mode was specified when Selecting components to copy.

RadioButton Copy data of all tables

Adds all tables of the source database to the Copy Database process.

RadioButton Copy data of tables selected on the previous step

Adds only the tables selected for copying their structure.

RadioButton Copy data of the selected tables

Adds only selected tables to the Copy Database process.

To select a table, you need to move it from the Available list to the Selected list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the tables from one list to another.

Copy Database Wizard - Selecting objects to copy their data

Click the Next button to proceed to the Setting additional options step of the wizard.


Setting additional options

This step allows you to customize common copying options and data options for the Copy Database process.

Copying Options

CheckBox Abort copying on error

This option determines whether the copying process should be stopped or forced to continue if an error occurs.

CheckBox Rollback on abort

Check the option to roll back the transaction when copying is aborted.

CheckBox Copy OID

Check this option to copy object OIDs as well. Note that this option is only available for PostgreSQL 8.1 and higher.

Copy Database Wizard - Setting additional options

Data Options

Records in block

Use the spinner control to define the number of records in each committed block.

CheckBox Commit data after each block

Check this option to add the COMMIT statement after a defined number of records.

When you are done, click the Next button to proceed to the Copying database step of the wizard.


Copying database

This step of the wizard is intended to inform you that all necessary options have been set, and you can start the Copy Database process.

The Operations tab allows you to view the log of operations and errors (if any).

Copy Database Wizard - Copying database

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed.

Click the Run button to complete the operation.


Compare Databases

Compare Databases Wizard creates an SQL script that provides database structure synchronization. To launch the wizard use the Tools | iconCompare Compare Databases... item of the main menu.

  • Selecting source database
  • Selecting target database
  • Selecting type of the synchronization script
  • Defining options for the destination script
  • Performing operation

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Copy Database Wizard

Backup Database

Restore Database

Using templates


Selecting source database

Use this step to define source database for comparing.

Database Comparer Wizard - Select the source database

Source host

Defines host where source database is located.

Source database

Select source database from the drop-down list.

Click the Next button to proceed to the Selecting source database step.

Use the templates button to save current settings to template or to restore settings from an existing template.


Selecting target database

Use this step to define target database for comparing.

Database Comparer Wizard - Specify the target database

Target host

Defines host where target database is located.

Target database

Select target database from the drop-down list.

Click the Next button to proceed to the Selecting type of the synchronization script step.

Use the templates button to save current settings to template or to restore settings from an existing template.


Selecting type of the syncrhonization script

SQL Manager for PostgreSQL
  • Index
  • « Prev
  • Next »

Selecting type of the synchronization script

Specify the direction of comparing selected database.

Database Comparer Wizard - Select the type of synchronization script

RadioButton Target database into source database

Enables reverse comparing: the synchronization script will contain statements which make the target database identical to the source one.

RadioButton Source database into target database.

Enables direct comparing: the synchronization script will contain statements which make the source database identical to the target one.

Click the Next button to proceed to the Defining options concerned destination script step.

Use the templates button to save current settings to template or to restore settings from an existing template.


Defining options for destination script

Use this step to define additional option for destination script.

Database Comparer Wizard - Select additional options

RadioButton Automatically load to Script Editor

With this option enabled, the synchronization script will not be saved. It will be loaded to Script Editor.

RadioButton Save to file

Use this option if you need to save the synchronization script to a file.

File name

Defines the name of the file to save the synchronization script to. Click the btnSaveAs Save button to locate file using the standard dialog or type the file name and it's location manually.

File charset

Specified character set will be used when saving the script to file.

Click the Next button to proceed to the final step.

Use the templates button to save current settings to template or to restore settings from an existing template.


Performing operation

This step of the wizard is intended to inform you that all necessary options have been set, and you can start comparing databases.

The log area allows you to view the log of operations and errors (if any).

Compare Database Wizard - Comparing database

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed. If the option is disabled then you can repeat the operation with the same or redefined parameters.

Click the Run button to run the backup database operation.

Use the templates button to save current settings to template or to restore settings from an existing template.


Print Metadata

Print Metadata allows you to generate and print metadata reports of any database object(s).

To open the window, select the Tools | btnPrintMetadata Print Metadata main menu item, or use the btnPrintMetadata Print Metadata button on the main toolbar. Alternatively, you can right-click the database alias in the DB Explorer tree and select the Tasks | btnPrintMetadata Print Metadata item from the context menu.

  • Using Navigation bar and Toolbar
  • Printing options
  • Print Preview

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Database Objects Management

Print Metadata options


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Print Metadata.

Print Metadata - Using Navigation bar

Database

iconDB select a database for the printing report

General

iconPrint print metadata of the selected object(s)

iconPreview preview the printing report

iconRestoreDefaultSize restore the default size and position of the window

Show

Tick filter database objects by type

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Printing options

The Print Metadata window allows you to select the database objects for printing metadata.

To select an object, you need to move it from the Available objects list to the Objects for printing list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the objects from one list to another.

After you select one or several objects, the Printing Options pane appears at the bottom.

Printing Options

Select an object in the Objects for printing list and specify items to be included into the printing report: DDL, Description (for all database objects), Columns/Params, Foreign Keys, Checks, Indexes, Triggers, Rules (for tables).

Print Metadata - Printing options

See also:

Using Navigation bar and Toolbar

Print Preview


Print preview

You can btnPrintPreview make a preview of the printing report and btnPrintMetadata print metadata for objects of the selected type using the corresponding items of the Navigation bar (or toolbar).

Print Metadata - Preview

The toolbar of the Preview window allows you to:

  • start printing the report;
  • open a previously saved printing report;
  • save the current report to an external *.fp3 file;
  • save the preview content to any of the available formats: HTML file, Excel file, Text file, RTF file, CSV file, HTML file, BMP image, Excel table (OLE), JPEG image, TIFF image (use the btnPreviewExport Export button for this purpose);
  • search for text within the printing report;
  • adjust zoom options;
  • enable/disable printing report outline;
  • enable/disable printing report thumbnails;
  • specify page settings;
  • edit the page using Report Designer;
  • navigate within the printing report pages;
  • close the Preview window.

See also:

Using Navigation bar and Toolbar

Printing options

Report Designer


HTML Report Wizard

HTML Report wizard allows you to generate a detailed HTML report of the selected database objects.

To start HTML Report Wizard, select the Tools | [image] HTML Report main menu item, or use the HTML Report [image] button on the main toolbar. Alternatively, you can right-click the database alias in the DB Explorer tree and select the Tasks | [image] HTML Report... item from the context menu.

  • Selecting database and directory
  • Selecting object types
  • Specifying CSS for HTML report
  • Setting additional report options
  • Creating HTML report

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Database Objects Management

Using templates


Selecting database and directory

In this step of the wizard you should select the source database and output directory for the HTML report.

Source database

Use the drop-down list of registered and connected databases to select the source database for the report.

Output directory

Type in or use the ExplorerButton button to specify the path to the output directory for the result HTML files using the Browse for Folder dialog.

HTML Report - Selecting database and directory

Click the Next button to proceed to the Selecting object types step of the wizard.


Selecting object types

Use this step of the wizard to select the types of objects to be included in the result HTML report.

HTML Report - Selecting object types

For your convenience the Select All and Unselect All buttons are implemented at the bottom of the objects list area.

Click the Next button to proceed to the Specifying CSS step of the wizard.


Specifying CSS

This step of the wizard allows you to edit the CSS (Cascading Style Sheet) file that will be used by the result HTML report.

HTML Report - Specifying CSS

Click the Next button to proceed to the Setting additional report options step of the wizard.


Setting additional report options

Use this step of the wizard to set additional HTML report options.

HTML Report - Setting additional report options

If needed, you can set optional text to Report header and Report footer of the result HTML report. For your convenience the default header and footer text is already available. If necessary, you can edit this text according to your needs.

DDL font size

This control allows you to set the font size for the DDL section. Move the slider between the small and large threshold values to select the required font size value within this scope. Note that the text size also depends on your browser settings.

Click the Next button to proceed to Creating HTML report.


Creating HTML report

This step of the wizard is intended to inform you that all necessary options have been set, and you can start the process.

The Operations tab allows you to view the log of operations and errors (if any).

HTML Report - Creating HTML report

CheckBox Show report after generating

This option opens the result report in your default browser after generating.

CheckBox Close the wizard after successful completion

If this option is selected, the wizard is closed automatically when the creating HTML report process is completed.

If necessary, you can save a template for future use.

Click the Run button to run the process.


Reports management

SQL Manager for PostgreSQL provides several tools for efficient reports management:

Create Report Wizard

This tool is used to simplify the process of creating reports.

Report Designer

It is a basic tool for creating powerful reports.

Report Viewer

Allows you to view created reports.

Reports can be stored either in the database (table pgmreports will be created to store them) or in a directory on your hard drive specified on the Directories page of the Database Registration Info dialog.


Create Report Wizard

Using Create Report Wizard you can create a report containing required datasets, bands and fields on them, with a definite report style applied.

To start the wizard, select the Database | iconNewObject New Object... main menu item, then select Report in the Create New Object dialog. Alternatively, you can right-click the Reports node of the DB Explorer tree and select the New Report... item from the context menu.

  • Specifying report name and options
  • Selecting report bands
  • Selecting report style
  • Specifying paper settings
  • Specifying margins
  • Specifying other page settings

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Report Designer

Report Viewer


Specifying database name and report options

Select the source database for adding a report and choose the action you need to perform: either create a new report or import an existing report from file.

Set the name for the new report and specify the save options for it:

RadioButton Save to database

The report will be created on the server inside the database.

RadioButton Save to file

If this option is selected, the report will be saved as a *.fr3 file to the directory specified on the Directories page of the Database Registration Info dialog.

Create Report - Specifying database name and report options

Click the Next button to proceed to the Selecting report bands step of the wizard.


Selecting report bands

This step of the wizard allows you to select the bands to be included in the report.

To select a band, you need to move it from the Available Bands list to the Report Bands list. Use the Items - Move to Selected Items - Move all to Selected Items - Move to Available Items - Move all to Available buttons or drag-and-drop operations to move the fields from one list to another.

Use the [image] Edit button to create datasets for 'data' bands using Design Query.

Create Report - Selecting report bands

Brief information about bands functionality is listed below. See FastReport Help for more information.

Name | Functionality
Report title | Prints once at the beginning of report
Report summary | Prints once at the end of report
Page header | Prints at the top of each page
Page footer | Prints at the bottom of each page
Master header | Prints at the beginning of master list
Master data | Data rows of master list
Master footer | Prints at the end of master list
Detail header | Prints at the beginning of detail list
Detail data | Data rows of detail list
Detail footer | Prints at the end of detail list
Subdetail header | Prints at the beginning of subdetail list
Subdetail data | Data rows of subdetail list
Subdetail footer | Prints at the end of subdetail list
Group header | Prints at the beginning of each group
Group footer | Prints at the end of each group

Click the Next button to proceed to the Selecting report style step of the wizard.


Selecting report style

Select the report style by clicking one of the images illustrating the styles available for the report.

Create Report - Selecting report style

Click the Next button to proceed to the Specifying paper settings step of the wizard.


Specifying paper settings

Specify report options: paper size and orientation, page margins, other settings.

Create Report - Specifying paper settings

Use the Margins tab to specify margins for the result report.

CheckBox Open the report after the wizard has finished

If this option is checked, the report will be opened in Report Designer after generating.

When you are done, click the Finish button to run the report generation process.


Specifying margins

CheckBox Stretch to print area

If this option is checked, the size of report is adjusted to the print area. If this option is unchecked, you can specify the left, right, top and bottom margins (in millimeters).

Create Report - Specifying margins

Use the Other tab to specify other page settings for the result report.

CheckBox Open the report after the wizard has finished

If this option is checked, the report will be opened in Report Designer after generating.

When you are done, click the Finish button to run the report generation process.


Specifying other page settings

Options

CheckBox Print to previous page

This option allows to use white space on a previous page. This option can be used in case when a report template consists of several pages or when printing batch (composite) reports.

CheckBox Two-pass report

If this option is selected, report's formation will be performed in two steps. During the first pass, a report is formed, and is divided into pages, but the result is not saved anywhere. During the second pass a standard report formation with saving a result in the stream is performed.

CheckBox Page numbering

This option allows to print a page numbers.

Columns

Number

This parameter specifies the number of columns for multi-column reports' printing.

Gap, mm

This parameter specifies the width of the gap between columns.

Create Report - Specifying other page settings

CheckBox Open the report after the wizard has finished

If this option is checked, the report will be opened in Report Designer after generating.

When you are done, click the Finish button to run the report generation process.


Report Designer

Report Designer allows you to create and edit reports. This tool can be opened after completion of Create Report Wizard to design a new report.

To edit an already existing project, use the appropriate Navigation bar item of Report Viewer.

This module is provided by Fast Reports, Inc. (http://www.fast-report.com) and has its own help system. Press F1 key in the Report Designer to call the FastReport help.

Please find the instructions on how to create a simple report in the Report Designer below:

  • Adding dialog form
  • Adding database and query components
  • Adding report data
  • Viewing the report
  • Saving the report

Note: The Object Inspector which allows you to edit report object properties, can be shown/hidden by pressing the F11 key.

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Create Report Wizard

Report Viewer


Adding dialog form

To add a dialog form, select the File | New Dialog main menu item in Report Designer.

The new dialog appears within the DialogPage1 tab of the designer. Use the available RAD tools to add necessary interface elements to the dialog.

Report Designer - Adding dialog form

To call the dialog, proceed to the Code tab and supply the corresponding statement (PascalScript), e.g.

begin

DialogPage1.ShowModal;

end.

Using the Language drop-down list you can select the script language to be used for the event handler: PascalScript (by default), C++Script, BasicScript, Jscript.

For instance, the following C++Script code can be used as the handler for the OnClick event of the 'Show' button to open ZeosPgQuery:

{

ZeosPgQuery1.Active = true;

}

See also:

Adding database and query components

Adding report data

Viewing the report

Saving the report


Adding database and query components

Adding database component

In order to add the Database component:

  • proceed to the Data tab of Report Designer;
  • pick the ZeosPgSQL Database [image] component on the toolbar (on the left);
  • click within the working area - the corresponding ZeosPgDatabase1 icon appears in the area;
  • set the database connection and authorization parameters using the Properties Inspector.

Report Designer - Adding database component

Adding query component

In order to add the Query component:

  • proceed to the Data tab of Report Designer;
  • pick the Zeos PgSQL Query [image] component on the toolbar (on the left);
  • click within the working area - the corresponding ZeosPgQuery1 icon appears in the area;
  • set the database name and authorization parameters within the Properties Inspector;
  • double-click the ZeosPgQuery1 icon to open the SQL window;
  • input the SQL query that returns the required dataset and click the btnPostEdit button;
  • repeat the operation if you wish to add other query components to the report.

Report Designer - Adding query component

Note: The Properties Inspector panel which allows you to edit report object properties can be shown/hidden by pressing the F11 key.

Using the above given steps you can create as many queries as you need. In order to select a dataset returned by a query, select the Report | Data... main menu item of Report Designer to call the Select Report Datasets dialog. Pick the required query within the dialog and press OK.

Report Designer - Selecting datasets

See also:

Adding dialog form

Adding report data

Viewing the report

Saving the report


Adding report data

Adding bands

In order to add a band to the report:

  • proceed to the Page1 tab of Report Designer;
  • pick the Insert Band [image] component on the toolbar (on the left);
  • select the band to be added to the report;
  • click within the working area - the corresponding element appears in the area;
  • set element properties within the Properties Inspector.

Report Designer - Adding bands

Adding report data

In order to add data to the report:

  • proceed to the Data tab within the panel on the right side of the window;
  • pick a column within the [image] Data tree and drag it to the working area;
  • add all necessary elements one by one using drag-and-drop operation for each of them.

Report Designer - Adding report data

Note: The Properties Inspector panel which allows you to edit report object properties can be shown/hidden by pressing the F11 key.

See also:

Adding dialog form

Adding database and query components

Viewing the report

Saving the report


Viewing the report

Viewing the report

To preview the newly created report, select the File | Preview main menu item or use the corresponding btnPrintPreview Preview toolbar button. You can also use the Ctrl+P shortcut for the same purpose. This mode allows you to view, edit and print the result report.

To print the report, use the btnPrint Print toolbar button or the corresponding context menu item.

Report Designer - Preview

It is also possible to preview/print the report using Report Viewer.

See also:

Adding dialog form

Adding database and query components

Adding report data

Saving the report


Saving the report

When all report parameters are set, you can save the report to an external *.fr3 file on your local machine or on a machine in the LAN.

To save the report, select the File | Save main menu item or use the corresponding btnSave Save Report toolbar button. You can also use the Ctrl+S shortcut for the same purpose.

If necessary, you can add the report to the database using Create Report Wizard and perform preview/print operations using Report Viewer.

See also:

Adding dialog form

Adding database and query components

Adding report data

Viewing the report


Report Viewer

Using Report Viewer you can view, edit, save and print reports.

Possible report operations are described on the Using Navigation bar and Toolbar page.

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Create Report Wizard

Report Designer


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Report Viewer.

Report Viewer - Using Navigation bar

Object

iconDB select a database

select a report for viewing

General

iconRefresh refresh the content of the window

edit report using Report Designer

iconSaveToFile save the current report

iconSaveToFileAs save the report to a *.fr3 file using the Save as... dialog

iconPrint print the report

iconRestoreDefaultSize restore the default size and position of the viewer window

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Search in Metadata

The Search in Metadata tool is implemented for quick search within the scope of database metadata. The tools allows you to set various search conditions and view the results.

To launch the Search in Metadata tool, select the Tools | iconSearchInMetadata Search in Metadata main menu item, or use the Ctrl+Alt+F shortcut.

  • Using Navigation bar and Toolbar
  • Setting search conditions
  • Viewing search results

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Database Objects Management


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Search in Metadata.

Search in Metadata - Using Navigation bar

The Navigation bar of the Search in Metadata tool allows you to:

Database

iconDB select a database for searching

General

iconSearchInMetadata set search conditions

iconRestoreDefaultSize restore the default size and position of the window

Explorer

iconDBExplorer browse the tree of found database objects

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Setting search conditions

The Find in metadata dialog allows you to set search conditions. It opens each time the Search in Metadata tool is launched.

Search in Metadata - Setting search conditions

Text to search

Enter a search string in this box. The Arrow-Down button which can be found next to the input box allows you to select any of the previously entered search strings.

Database

Use the drop-down list to select a database for the search operation.

Options

CheckBox Search in DDL

This option includes object definition in search scope.

CheckBox Case sensitive
This option can be used to differentiate uppercase characters from lowercase ones during the search process.

CheckBox Whole words only
Use this option to search for words only (with this option off, the search string might be found within longer words.

CheckBox Regular expressions
Recognizes regular expressions in the Text to find field.

For example, you can type "empl*" to search for metadata containing the "empl" substring; enter "^emp" to search for words starting with "emp" or "^emp|emp$" to search for the string "emp" at the beginning or at the end of the string.

Note: The syntax of regular expressions that can be used in the Text to find field is similar to that used in Perl regular expressions. Comprehensive information about it can be found at http://perldoc.perl.org/perlre.html#Regular-Expressions.

Direction

RadioButton Forward

Searches from the current position to the end of the working area.

RadioButton Backward

Searches from the current position to the beginning of the working area.

CheckBox Display results in separate window

This option enables displaying results in a separate window. Otherwise search results replace the current search.

See also:

Find Text dialog


Viewing search results

The Search in Metadata window allows you to view the search progress and results fetched from the database.

Search in Metadata - Viewing search results

After the search is complete, the Explorer group on the Navigation bar displays the tree of database objects in which the search string is found, and allows you to view metadata of the required object or its fragment quickly by clicking enclosed object branches in the tree.

The Object <object_name> area is provided for viewing metadata of the objects, with the search string highlighted.

For your convenience the syntax highlight, code completion and a number of other features for efficient SQL editing are implemented. For details see Working with Query Data area and Using the context menu.


Database Designer

Database Designer is provided for visual presentation of databases, database objects and relations between objects. It also allows you to create, edit and drop tables and table columns, set relations between tables and perform other operations you may need to achieve your purpose.

To open the designer, select the Tools | btnVDBD Database Designer main menu item, or use the btnVDBD DBD button on the main toolbar.

  • Using Navigation bar and Toolbars
  • Using Diagram Navigator and DB Objects pane
  • Using context menus
  • Adding/removing objects to/from diagram
  • Incremental search
  • Creating new objects
  • Creating relations
  • Working with diagram pages
  • Reverse engineering
  • Printing diagram
  • Saving/loading diagram
  • Setting diagram options

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Database Objects Management

Database Designer options


Using Navigation bar and Toolbars

The Navigation bar and Toolbars provide quick access to tools implemented in Database Designer.

VDBD - Using Navigation bar

Database

iconDB select a database for building the diagram

File group

iconNew create a new diagram;

iconLoadFromFile open an existing diagram;

iconSaveToFile save the current diagram to a *.pgd file;

iconSaveToFileAs save the current diagram as a custom file

Navigator

Tick use Diagram Navigator

General group

cancel latest modification;

repeat canceled modification;

iconRefresh refresh objects in the diagram;

iconProperties Print setup - define printing settings;

iconPrint print the diagram;

iconPreview show Print Preview;

iconOptions edit diagram options

iconRestoreDefaultSize restore the default size and position of the window

Pages group:

add a new page;

delete the current page;

delete all pages.

Database Objects

VDBD - Database Objects pane

contains the list of objects (tables, views and functions) that can be placed to diagram.

Context menu of Database Objects group allows you to:

iconFindText search for objects in the diagram using the Database Objects pane;

iconPlus add objects to the diagram using the Database Objects pane;

switch objects view: As tree/As list;

enable/disable sorting by schema, object name or object name, schema;

iconRefresh refresh list of objects.

NB: You can enable\disable Toolbars and Navigation bars at Environment options.

The main toolbar (by default, the toolbar is located at the top of the diagram area) contains a number of tools (including items of the Navigation bar, context menu, tools for printing diagram, etc.) allowing you to:

iconDB select the database for building the diagram;

iconNew create a new diagram;

iconLoadFromFile open an existing diagram;

iconSaveToFile save the current diagram to a *.pgd file;

iconSaveAsPicture save the current diagram as an image;

activate the Incremental search panel;

  • adjust diagram zoom for optimal representation: iconZoomIn zoom in, iconZoomOut zoom out, iconZoomFitModel fit model;

iconZoomSelectRectangleToFit switch cursor mode: select / select rectangle to fit;

iconPrintSetup open the Print Setup dialog;

iconPrint print the diagram;

iconPreview show Print Preview;

iconAlwaysOnTop arrange objects in the diagram;

btnExtractDB extract metadata of all objects in the diagram and load the script to Execute Script Editor;

btnReverseEngineer perform Reverse Engineering;

iconRefresh refresh objects in the diagram;

iconOptions view/edit diagram options;

  • specify a predefined zoom value;

iconRestoreDefaultSize restore the default size and position of the window.

Object Customization panel allows you to define font, font size, font style, font color and brush color.

VDBD - Toolbars - Main

The Pages toolbar (by default, the toolbar is located at the top of the diagram area) contains tools for working with diagram pages allowing you to:

add a new page;

delete the current page;

delete all pages.

Diagram toolbar located on the left allows you to:

switch to object selection mode;

switch to create table mode (enables creating tables on clicking);

switch to create relation mode;

switch to create virtual relation mode;

switch to create comment mode;

align left edges;

align right edges;

align tops;

align bottom;

align horizontal centers;

align vertical centers;

space equally, horizontal;

space equally, vertical.

The New object toolbar (by default, the toolbar is located on the left side of the diagram area) allows you to:

  • set the cursor mode to Select;
  • create a new object (a table or a comment);
  • create a new relation;

VDBD - Toolbars - New object

See also:

Using Diagram Navigator and DB Objects pane

Using context menus

Adding/removing objects to/from diagram

Incremental search

Creating new objects

Creating relations

Working with diagram pages

Reverse engineering

Printing diagram

Saving/loading diagram

Setting diagram options


Using Diagram Navigator and DB Objects panel

To navigate within the large diagram, use the Navigator tool available on the Navigation bar. It allows you to see the whole diagram in a reduced scale and to perform a number of operations over the diagram objects.

VDBD - Diagram navigator

A mouse click in the Navigator area sets the center of the visible diagram area. The area currently visible in the main diagram area is outlined in a red bounding rectangle.

Using the Navigator you can work with the diagram objects in the same way as in the main diagram area: add/remove, create new objects, move objects within the diagram and perform other operations.

The Database Objects pane available on the Navigation bar allows you to browse the list of available database objects that can be added to the diagram.

VDBD - Database Objects pane

Select and drag an object to the diagram area or double-click it to add the object to the diagram.

Right-click an item within the list to call the context menu allowing you to:

iconFindText find the selected object in the diagram (if the object is found, it will be highlighted in the diagram area);

iconPlus add new objects to the diagram by Reverse engineering;

Tick toggle objects representation mode: as a tree / as a list;

Tick select the sorting mode applied to the objects in the list: by schema, name / by name, schema;

iconRefresh refresh the list.

See also:

Using Navigation bar and Toolbars

Adding/removing objects to/from diagram

Creating new objects

Creating relations

Working with diagram pages


Using context menus

The context menu of the diagram area contains a number of items available in the Navigation bar and toolbars and allows you to:

  • select all objects in the diagram area;
  • Select All Headers;
  • Select All Columns;
  • adjust diagram zoom for optimal representation: zoom in, zoom out, select rectangle to fit, fit model, specify a predefined zoom value;
  • set the cursor mode to Select or create a new table, relation, or comment;
  • configure the grid: draw grid, snap to grid;
  • adjust the diagram style: draw primary key columns separately, draw entities icons, draw attributes icons, draw only names ofentities, draw foreign key names;
  • perform Reverse Engineering;
  • extract metadata of the diagram objects to Execute Script Editor;
  • view/edit diagram options.

VDBD - Using context menu

The context menu of an entity contains items for working with the object and allows you to:

  • edit the object using its editor;
  • create a new object using its editor;
  • drop the object from the database;
  • show/hide object subitems;
  • remove the object from the diagram.

VDBD - Using entity context menu

The context menu of a column contains items for working with the object and its columns and allows you to:

  • edit the selected column using its editor (Column Editor);
  • create a new column;
  • drop the selected column;
  • edit the object using its editor (Table Editor);
  • create a new object using its editor (New table);
  • drop the object from the database;
  • show/hide object subitems;
  • remove the object from the diagram.

VDBD - Using field context menu

See also:

Using Navigation bar and Toolbars

Adding/removing objects to/from diagram

Incremental search

Creating new objects

Creating relations


Adding/removing objects to/from diagram

To add an object to the diagram:

  • drag it from the Database Explorer tree to the diagram area

or

  • drag it from the Database Objects pane (available on the Navigation bar) to the diagram area or simply double-click this object in the list.

To add objects by Reverse engineering, you can right-click within the Database Objects list and select the iconPlus Add new objects... context menu item.

To remove an object from the diagram, select it in the diagram area, then right-click its title and choose the Remove <object_name> item from the context menu, or just press the Del key.

VDBD - Removing objects from diagram

See also:

Using Navigation bar and Toolbars

Using Diagram Navigator and DB Objects pane

Using context menus

Creating new objects

Creating relations

Reverse engineering

Database Objects Management


Incremental search

To search for an object within the diagram:

  • right-click the required object in the Database Objects pane and select the btnFindText Find Object in Diagram item from the context menu

or

  • click the [image] Incremental Search button on the main toolbar or use the Ctrl+F shortcut to activate the Incremental Search panel in the status bar area of the designer window.

VDBD - Incremental Search

Type a string in the edit-box, and the object having the name with the closest match will be highlighted in the diagram area.

See also:

Using Diagram Navigator and DB Objects pane


Creating objects

To create a new object using Database Designer:

  • press the Create table/view/function button on the New object toolbar;
  • click the desired point on the diagram to place the new object at;
  • specify object properties using its editor (New table).

VDBD - Creating new table

Hint: To create a new object, you can also select the corresponding item from the context menu. The context menus also allow you to edit and drop database objects.

Note: Before you press the iconCompile Compile button the object is created on the diagram area only but not in the database.

See also:

Using Diagram Navigator and DB Objects pane

Adding/removing objects to/from diagram

Incremental search

Creating relations


Creating relations

To establish a new relation (which is the foreign key in terms of database management):

  • press the Create relation button on the New object toolbar;
  • click the entity where the referential constraint should be created;
  • click the referred entity;
  • specify new foreign key properties using Foreign key Editor.

VDBD - Creating relations

Hint: To create a relation, you can also use the corresponding item of the context menu.

Once the relation is created, it is displayed as a line between two entities in the diagram area. The style the line is drawn is determined by the diagram notation.

The context menu of this line allows you to edit the foreign key using Foreign key Editor or drop the foreign key from the database.

VDBD - Creating relations - Context menu

See also:

Using Diagram Navigator and DB Objects pane

Adding/removing objects to/from diagram

Incremental search

Creating new objects


Working with diagram pages

SQL Manager for PostgreSQL
  • Index
  • « Prev
  • Next »

Working with multiple diagram pages

You can create several pages in one diagram to split the model into several subject groups, e.g. for better comprehension.

To manage diagram pages, right-click on the tabs at the bottom of the diagram area and select the required popup menu items for adding, deleting and renaming pages.

VDBD - Working with diagram pages

Hint: Page management items are also available on the Pages toolbar of Database Designer.

See also:

Using Diagram Navigator and DB Objects pane

Adding/removing objects to/from diagram


Reverse engineering

The reverse engineering operation builds relationship diagram on the basis of the current database's structure. The objects are arranged automatically within the diagram model.

To start the reverse engineering process, press the Reverse Engineer btnReverseEngineer button on the main toolbar, or use the corresponding item of the context menu.

VDBD - Reverse engineering

The Preparing Reverse Engineering dialog allows you to select schemas containing objects to reverse engineer.

VDBD - Reverse engineering - Select schema

For your convenience the Select All and Deselect All items are available in the context menu of the schemas list.

See also:

Using Navigation bar and Toolbars

Using Diagram Navigator and DB Objects pane

Adding/removing objects to/from diagram


Printing diagram

Database Designer allows you to print and preview the diagram.

To preview the diagram:

  • press the btnPrintPreview Print Preview button on the toolbar;
  • preview the diagram using the Print Preview window.

To setup print options:

  • press the btnPrintSetup Print Setup button on the toolbar, or use the corresponding link on the Navigation bar;
  • set printing options using the Print Setup dialog and press OK.

To print the diagram:

  • press the btnPrintMetadata Print button on the toolbar;
  • set printing options using the Print Setup dialog and press the Print button.


Print Preview

The Print Preview dialog allows you to see the diagram layout in WYSIWYG mode before it will be printed.

Use the navigation buttons or the spinner control to navigate within the preview pages.

Click the Print options... button to call the Print Setup dialog.

If necessary, specify the preview zoom according to your preferences.

Click the Print all button to start printing.

VDBD - Printing diagram - Print Preview

See also:

Print Setup dialog


Print Setup dialog

The Print Setup dialog of Database Designer provides two tabs for setting printing options: Printer and Page options.

The Printer tab of the Print Setup dialog allows you to:

  • specify the printer (use the Choose printer button to select a printer which is not set by default on your system; the name, driver, port fields display the selected printer details);
  • specify print layout: print using a defined scale factor or arrange diagram at a defined number of pages horizontally and vertically;
  • set other print options.

Database tools - VDBD - Print Setup - Printer

The Page options tab of the Print Setup dialog allows you to:

  • specify page margins (in millimeters): Top margin, Bottom margin, Left margin, Right margin;
  • specify Page header and Page footer: enter the header/footer running titles text, set left/center/right align.

Database tools - VDBD - Print Setup - Page options

Hint: It is also possible to set macros in the Page header and Page footer fields:

#PCOUNT stands for the quantity of pages;

#PAGE - the number of the current page;

#DATE denotes the current date;

#TIME denotes the current time.

See also:

Print Preview


Saving/loading diagram

Use the btnSave Save Diagram and the ExplorerButton Open Diagram buttons on the main toolbar to save the diagram as a *.pgd file for future use or to load the previously saved diagram.

VDBD - Saving and Loading diagram

If necessary, you can save the diagram as an image: click the btnSaveAsPicture Save as Picture button on the on the main toolbar.

See also:

Using Navigation bar and Toolbars

Using Diagram Navigator and DB Objects pane

Using context menus

Adding/removing objects to/from diagram


Setting diagram options

Using the Diagram Options dialog you can setup the behavior and look of each diagram page.

To open this dialog, use the btnEnvironmentOptions Diagram options item of the Navigation bar or on the main toolbar, or select the corresponding item from the context menu.

See detailed description of each option on the Database Designer page of the Environment Options dialog.

CheckBox Apply changes to all new pages

If this option is selected, the current settings will be applied to all newly created pages of Database Designer.

See also:

Using Diagram Navigator and DB Objects pane

Database Designer options


External Tools

When using SQL Manager for PostgreSQL, you can add external Windows applications to make your work more efficient.

  • External Tools dialog
  • External Tool Info editor

Adding External Tools

  • select the Options | External Tools... main menu item;
  • click the Add... button in the External Tools dialog;
  • specify parameters of the new external tool within the External Tool Info editor;
  • confirm adding the new external tool by clicking OK in the External Tool Info editor and the External Tools dialog.

This adds the icon and the title of the application you have selected to the Tools | External Tools submenu. Now you can run this tool quickly without closing SQL Manager.

Removing External Tools

  • select the Options | External Tools... main menu item;
  • select the tool to be removed in the Tools list of the External Tools dialog;
  • press the Del key or click the Delete button within the dialog;
  • click OK to confirm removing the tool and closing the dialog.

The selected tool has been removed and is no longer accessible from the Tools | External Tools submenu.

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Database Tools

Services

Server Tools

Options

How To...


External Tools dialog

The External Tools dialog allows you to manage the list of external applications which can be easily run from within SQL Manager environment.

To open this dialog, select the Options | iconExternalTools External Tools... main menu item.

Tools

Lists all added external applications.

Add...

Opens the External Tool Info editor for adding a new tool to the Tools | External Tools submenu.

Edit...

Opens the External Tool Info editor for editing the title, the hot key, the path to the executable file, the working directory and execution parameters of the tool currently selected in the Tools list.

Delete

Removes the selected tool from the list of SQL Manager for PostgreSQL external tools.

External tools - External Tools dialog

To change the order of tools in the list, use the [image] [image] arrow buttons at the bottom area of the dialog, or use the Ctrl+Shift+Up / Ctrl+Shift+Down shortcuts. You can also drag-and-drop items within the list box to change their positions.

See also:

External Tool Info editor


External Tool Info editor

The External Tool Info editor allows you to set common parameters of running added external programs from within SQL Manager environment. This dialog is used both when adding external tools and editing their parameters (see Add External Tool and External Tools).

Title

Enter the title to be displayed in the Tools | External Tools submenu of SQL Manager.

Hot Key

Press a key or a key combination to set it as a hot key for running the tool.

Program

Use the ExplorerButton Explorer button to specify the path to the *.exe file of the external program.

Working Dir

Set the default working directory of the program.

Parameters

This box stores parameters for the program execution (if required).

External tools - External Tool Info editor

See also:

External Tools dialog


How To...

This section contains brief information about basic operations which can be preformed in SQL Manager for PostgreSQL.

Work with Servers

Register Host

Unregister Host

View Server Log SQL Parser

View Server Configuration

View Server Status

Work with Databases

Create Database

Register Database

Connect to Database

Disconnect from Database

View Database Info

View Database Registration Info

Enable Login Prompt for Database

Enable System Objects Display

Change Database Default Charset

Change Database Sort Order in DB Explorer

Design Database Visually

Add Objects to Diagram

Extract Database Objects Structure and Data into SQL Script

Backup Database

Restore Database from Backup

Analyze Tables

Vacuum Tables

Reindex

Database Statistics

Work with Database and Server Objects

Create New Object

Duplicate Object

Edit Object

Rename Object

Group Objects

Drop Object

Find Object in the Tree

View Object Dependency

View Object DDL

Work with Data

Work with Records

Add Records to Table

Edit Record

Save Record in Table

Add Image to Table

Cancel Data Changes

Delete Record from Table

Changing DB font charset

Sorting

Filtering

Grouping

Change Number of Visible Records

Set Data Display Format

Enable\Disable Transaction Confirmation

Export Data

Import Data

Export Data as SQL Script

Load Data

Save Data

Work with Queries and Scripts

Work with Queries

Open SQL Editor

Open Visual Query Builder

Create Query

Export Query Results into File

Work with Several Queries at Once

Edit Query in Visual Query Builder

Work with SQL Scripts

Open SQL Script Editor

Create SQL Script

Making Script Work Faster

Create SQL Script Based on Object

Working with Query/Script Text

Execute Query/Script

Save Query/Script as Favorite Query

Load Query/Script from File

Save Query/Script to File

View Executed Queries and Scripts

Work with Data Reports

Create Report

Create Simple Report in the Report Designer

Save Report in Database

Save Report to File

View Report

Edit Report

Print Report

Work with Metadata Reports

Representing Metadata as Report

Create HTML Report of Database Objects Metadata

View Objects Metadata

Save Report

Viewing HTML Report

Edit Report

Print Report

Update SQL Manager

Manager Access to Database

Managing users and roles

Granting permissions

Managing Changes

Enabling Change Management

Disabling Change Management

Creating Label/Branch/Tag

Checking Repository

Adding Changes to Repository

Releasing New Version of Database

Browsing History of Changes

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Database Tools

Server Tools

Personalization

External Tools


Work with Database and Server Objects

SQL Manager for PostgreSQL provides user with all necessary tools to manage database and server objects.

Note: To start working with objects connection to database must be established.

Database objects

Schemas

Schema objects:

Tables

Views

Functions

Domains

Rules

Sequences

Data types:

Base Types

Composite Types

Enumerated Types

Aggregates

Operators

Other objects:

Tablespaces

Languages


Duplicate Object

You can copy an object in one of the following ways:

  1. Choose Duplicate<object type><object name> in the object context menu and define the necessary parameters in the Duplicate Object Wizard.
  2. Choose Database | Duplicate object in the main program menu and define the necessary parameters in the Duplicate Object Wizard.


Edit Object

You can open an object in the corresponding object editor in one of the following ways:

  1. Open an object by double clicking it in the DB Explorer.
  2. Choose Edit<object type><object name> in the object context menu in the DB Explorer.
  3. Use the shortcut <Ctrl + o>.


Rename Object

You can rename an object in one of the following ways:

  1. Choose Rename<object type><object name> in the object context menu.
  2. Use the shortcut <Ctrl + R>.

Note: Some types of objects cannot be renamed.

The CheckBox Rename objects by editing in place option located in the DB Explorer tab of the Environment Options dialog enables/disables renaming of objects in DB Explorer on single-clicking the object.


Group Objects

You can group objects using projects or DB Explorer tabs.

The Projects folder can be found in the DB Explorer tree. Objects can't be placed to the root of this folder. You need to create a subfolder to place objects there.

There are few ways to unite objects in project:

  1. Create New Sub Folder in the Projects folder using the corresponding item of the context menu, then define its name and drag-and-drop needed objects there.
  2. Create New Sub Folder in the Projects folder using the corresponding item of the context menu, then define its name and use the Add Object item of the created folder context menu. Pick the objects to add to folder from the appeared dialog.

Grouping using DB Explorer tabs

To place object on the separate tab:

  1. Use the btnNewTabFromHere New Tab from Here item of the object context menu.

Note: If object is not a tree node, it cannot be placed on separate tab.


Drop Object

You can drop an object in one of the following ways:

  1. Choose Drop<object type><object name> in the object context menu.
  2. Use the shortcut <Shift + Del>.


View Object DDL

To view DDL of object:

  1. Open object in editor, then switch to the DDL tab.
  2. Define SQL Assistant to show object details, then DDL of the object selected in DB Explorer will be displayed in SQL Assistant.

To open DDL of object in edit mode use the btnShowSQLEditor Open DDL in SQL Editor button on the toolbar.


Work with Records

You can view and edit table data on the Data tab and queries results are available on the Results tab. The special tool is used for viewing and editing data - Data View.

The Data View is used in:

Table Editor

View Editor

Query Editor

Visual Query Builder, etc.


Add Records to Table

You can add records to a table in one of the following ways:

  1. Open a table at the Data tab and press the HowTo - Grid View - Insert Record Insert Record button in the Data Management section of the navigation bar. Insert data in the new line and save changes by pressing Post Edit.
  2. Open a table at the Data tab and proceed to the Form View tab. Press the HowTo - Grid View - Insert Record Insert Record button on the Data Management section of the navigation bar, insert data in the new line and save changes by pressing the HowTo - Grid View - Post Edit Post Edit button.
  3. Use the shortcut Insert.

Note: If the transaction confirmation is enabled, then in order to commit transaction, press Commit transaction.


Edit Record

To edit a record in the table, open the table at the Data tab, choose the record for editing and press the HowTo - Grid View - Edit Record Edit Records button, or click the needed cell, edit it and save changes by pressing the HowTo - Grid View - Post Edit Post Edit button

Note: If the transaction confirmation is enabled, then in order to commit transaction, press Commit transaction.


Save Record in Table

After adding or editing data in a table, you can save it by pressing the HowTo - Grid View - Post Edit Post Edit button in the Data Management section of the navigation bar.

Note: If the transaction confirmation is enabled, then in order to commit transaction, press Commit transaction.


Add Image to Table

Adding images to table is possible only if table contains at least one BLOB field.

To add image to table, open the table on the Data tab, go to the BLOB View section (the navigation buttons are located in the bottom part of the window) and then proceed to the Image tab. If there are several BLOB fields, choose the required field

HowTo - Grid View - BLOBView - Select BLOB Column

from the Select BLOB Column drop-down list on the toolbar of the Blob View tab and press the ExplorerButton Load from File button on the same toolbar. Choose the needed image file in the appeared dialog.


Changing DB font charset

Changed font charset is applied to the whole database.

To change charset, open the Database Registration Info dialog, select the Connection tab there and use the Font charset drop-down list to change database charset.


Sorting

In order to sort data, do the following:

Open data at the Data or Results tab, choose the column by which you need to sort data and click the column title.

If the column was not sorted, the first click will sort it in the ascending order and the second one - in the descending order.

Clear Sorting

To cancel the sorting, open the context menu by right-clicking the necessary column and choose the Clear Sorting item.


Filtering

Quick Filtering (by the current value in a cell)

Open the context menu of the needed column and choose the Quick Filter item. Then choose a filter condition in the opened submenu.

Filtering by Column

HowTo - Grid View - Quick Filter

Open the drop-down list on the column title and choose a filter condition from the list.

You can set advanced conditions by using the Custom... menu item.

When choosing this item, the special window for setting filter conditions opens.

Advanced Filtering

You can set advanced filter options by pressing the button btnSetFilter on the toolbar of the Data View and set filter parameters in the Filter Builder. Apply the set conditions by pressing the Apply button.

If a filter is set for a table, the special bar appears in the lower part of the table where you can see filter conditions and the history of filter changes opened by pressing the drop-down list.

This bar allows you to:

  • disable filter by pressing the button btnClose ,
  • enable filter by checking the box with the necessary condition,
  • change filter conditions by using the Customize... button. This button opens the Filter Builder.

Data View - Grid View - Filtering records - Filtering panel

Disable Filtering

To cancel filtering, open the context menu of the column and choose the Disable filter item.

Or press the button btnClose on the filter toolbar.


Grouping

Grouping

To enable grouping, drag the column title to the special grouping car above the table.

HowTo - Data View - Grid View - Grouping data by two columns_Small

Cancel Grouping

To disable grouping, drag the column title from the group bar back to the table.


Enable\Disable Transaction Confirmation

You can enable\disable the confirmation for transactions in the following ways:

  1. Choose Options | btnEnvironmentOptions Environment Options in the main program menu, proceed to the Confirmations tab and check\uncheck the CheckBox Confirm transaction commit box.
  2. Choose btnEnvironmentOptions Properties in the Data View context menu, proceed to the Confirmations tab and check\uncheck the CheckBox Confirm transaction commit box.


Экспорт

SQL Manager for PostgreSQL
  • Index

Export Data

You can export data from a database table into an external file of any supported format in one of the following ways:

  1. Open the Data or Results tab, press [image] Export Data on one of the Data View toolbars and set export parameters in the opened Data Export wizard.
  2. Open the Data or Results tab, choose Data Manipulation | Export Data in the Data Grid context menu and set export parameters in the opened Data Export wizard.
  3. Open the table context menu in the DB Explorer, choose the Export Data item and set export parameters in the opened Data Export wizard.
  4. Open the Data or Results tab and use the shortcut Ctrl+E.


Open SQL Editor

btnShowSQLEditor You can open SQL Editor in one of the following ways:

  1. Choose Tools | Show SQL Editor in the main program menu,
  2. Press the btnShowSQLEditor Show SQL Editor button on the standard toolbar of the program.
  3. Use <F12>.


Open Visual Query Builder

btnShowQueryBuilder You can open the Visual Query Builder in one of the following ways:

  1. Choose Tools | Show Query Builder in the main program menu.
  2. Press the Show Query Builder btnShowQueryBuilder button on the standard toolbar of the program.


Create Query

Create Query in SQL Editor

  1. Choose Tools | btnNewSQLEditor New SQL Editor in the main program menu and write the query text in SQL Editor.
  2. Press the btnNewSQLEditor New SQL Editor button on the standard toolbar of the program and write the query text in SQL Editor.
  3. Use the shortcut <Shift+F12> and write the query text in SQL Editor.

Create Query in Query Builder

You can create a query in one of the following ways:

  1. Choose Tools | btnNewQueryBuilder New Query Builder in the main program menu and create a query in the Visual Query Builder.
  2. Press the btnNewQueryBuilder New Query Builder button on the standard toolbar and build a query on the diagram or in the editor area of the Visual Query Builder.
  3. Open btnShowSQLEditor SQL Editor or btnShowQueryBuilder Query Builder, drag any object from DB Explorer to SQL Editor or Visual Query Builder, select the type of the created query in the opened window.

Create simple query in Query Builder

  1. Open Visual Query Builder.
  2. Drag object from the DB Explorer tree or Objects group to the diagram area.
  3. Include the field in the query. Check the corresponding box located to the left from the field name in the list, or just double-click it. To include all fields of the table/view, check the box located to the left of the table/view caption. If you do not check any fields, the SQL statement is generated as SELECT * FROM <table/view_name>, i.e. all the fields are included in the query.
  4. Associate two objects by their fields. This operation is performed by dragging a field from one object list to another to set a link between these objects by the selected fields. It is indicated by a bidirectional arrow between the linked fields.
  5. Set the link properties using the linking arrow. The hint containing the association condition will popup after a short delay. To edit the link properties, double-click the linking arrow or right-click it and select the Property popup menu item. The Link properties dialog allows you to change the linking condition by choosing it from the drop-down list (=, >, <, >=, <=, <>).


Edit Query in Visual Query Builder

Open the btnShowQueryBuilder Query Builder, edit the visual query scheme on the Builder tab, and make the necessary changes to a query text on the Edit tab.


Open SQL Script Editor

You can open SQL Script Editor in the following ways:

  1. Choose Tools | SQL Script in the main program menu.
  2. Press the btnShowSQLScript SQL Script button on the standard toolbar of the program.
  3. Use the shortcut <Ctrl+Shift+S>.


Create SQL Script Based on Object

You can create SQL script based on the object in one of the following ways:

  1. Choose Script to new SQL Editor in the object context menu and choose the script type.
  2. Open btnShowSQLEditor SQL Editor or btnShowQueryBuilder Query Builder and drag any object from the DB Explorer into Query Editor or Visual Query Builder. Choose the type of the created query in the opened window.


Save Query/Script as Favorite Query

Save Query as Favorite Query

  1. Create a new query or open an existing one in SQL Editor, choose the [image] Save to favorite Queries item on of the toolbars or in the context menu and in the opened window specify the query name in the Name filed, the storage type in the Storage field.
  2. Create a new query or open an existing one in the Visual Query Builder, proceed to the Edit tab, choose the [image] Save to favorite Queries item in the context menu and in the opened window specify the query name in the Name filed, the storage type in the Storage field.

Save Script as Favorite Query

Create a new script or open an existing one in SQL Script Editor, choose the [image] Save to favorite Queries in the context menu, in the opened window specify the script name in the Name field and the storage type - in the Storage field.


Load Query/Script from File

To iconLoadFromFile Load Script from file:

  1. Open btnShowSQLScript SQL Script Editor, then click the iconLoadFromFile Load SQL item of the navigation bar and define the source file in the appeared window.
  2. Open btnShowSQLScript SQL Script Editor, then press Ctrl+L and define the source file in the appeared window.

To iconLoadFromFile Load SQL Query from file:

  1. Open btnShowSQLEditor SQL Editor or btnShowQueryBuilder Query Builder, then click the iconLoadFromFile Load SQL item of the SQL Editor navigation bar or iconLoadFromFile Load diagram item of the Query Builder navigation bar and define the source file in the appeared window.
  2. Open btnShowSQLEditor SQL Editor or btnShowQueryBuilder Query Builder, then press Ctrl+L and define the source file in the appeared window.
  3. Open btnShowSQLEditor SQL Editor, then click the iconCompile Execute script from file item of the navigation bar.


Save Query/Script to File

To save script to file:

  1. Create new script or open an existing one, then click the iconSaveToFile Save script item of the navigation bar and define target file name and location in the appeared window.
  2. Create new script or open an existing one, then press Ctrl+S and define target file name and location in the appeared window.

To save query to file:

  1. Create new query or open an existing one, then click the iconSaveToFile Save SQL item of the SQL Editor navigation bar, or iconSaveToFile Save diagram item of the Query Builder navigation bar and define target file name and location in the appeared window.
  2. Create new query or open an existing one, then press Ctrl+S and define target file name and location in the appeared window.

Export Query Results into File


View Executed Queries and Scripts

btnSQLMonitor View Executed Queries and Scripts

SQL Monitor allows viewing all scripts that SQL Manager for PostgreSQL sends to the server, as well as their results. You cannot edit the data but you can copy it, save to file and print.

All means for working with SQL Monitor are located at toolbars and in context menu.

You can open SQL Monitor in the following ways:

  1. Select Tools | SQL Monitor from the main program menu.
  2. Press the SQL Monitor button on the main toolbar.
  3. Select Tasks | SQL Monitor from the database context menu.

Note: SQL Monitor displays only those scripts and queries executed in SQL Manager for PostgreSQL during current session. If opened constantly, SQL Monitor can slow down program performance.


Work with Data Reports

The report is an effective way to present data in the printable format. It allows representing data in the desired way changing the size and view of all report elements.

Data Reports

These reports are connected to one or several databases and database queries. The sources for such reports are fields of basic tables and queries.

Tools for working with reports

Create Report Wizard - intended for quick step by step creation of a data report blank. The data source, visible areas and page parameters are defined.

Report Designer - a separate tool for creating data reports.

Report Viewer - a tool used when opening a report from DB Explorer.

The reports can be stored in a database as database objects in the Reports section of the DB Explorer or in external files with a *.fr3 extension.

See also:

Work with metadata reports


Create Report

Represent Data as Report

  1. Choose Database | New Object in the main program menu, choose the [image] Report object type in the opened window and set the necessary report parameters in the opened Create Report Wizard.
  2. Open the drop-down list of objects by pressing Create on the toolbar and choose the Report item, set the necessary report parameters in the opened Create Report Wizard.
  3. Choose the New Report item in the Reports group context menu in the DB Explorer and set the necessary report parameters in the opened Create Report Wizard.
  4. Choose the [image] New Report item in the Report object context menu in the DB Explorer and set the necessary report parameters in the opened Create Report Wizard.
  5. Choose Tools | [image] Report Designer in the main program menu and set the necessary report parameters in the opened Report Designer.


Create Simple Report in the Report Designer

To create a report using Report Designer:

  1. Select the Tools | [image] Report Designer main menu item.
  2. In the opened Report Designer select the File | [image] New Report main menu item, or click the [image] New Report item of the navigation bar. The following objects will be added to the newly created report: ReportTitle, MasterData and PageFooter.
  3. Connect to data source.
  4. Add ADOTable or ADOQuery object.
  5. Link ADOTable or ADOQuery with ADODatabase.
  6. Place database fields Page1. Move the required fields from DataTree to Band MasterData.


Save Report in Database

  1. When creating a report in the Create Report wizard, on Step 1 choose Save to database in the Save Options section.
  2. Open the needed report from the DB Explorer and choose the iconSaveToFile Save report item on one of the Report Viewer toolbars.


Edit Report

To edit report:

  1. Open the needed report in the Report Viewer from the DB Explorer tree, then click the [image] Edit Report item of the navigation bar or toolbar and make necessary changes using the appeared Report Designer.
  2. In the main menu pick the Tools | [image] Report Designer item, then select the File | Open item in the Report Designer menu and in the appeared window define the file to open for editing.


Print Report

To print report:

  1. Open the needed report from DB Explorer tree, then click the iconPrint Print item of the navigation bar or toolbar.
  2. Select the Tools | [image] Report Designer main menu item, then pick the File | Preview item of the Report Designer menu and click the iconPrint Print link on the navigation bar or toolbar.


Work with Metadata Reports

Report is an effective tool for presenting metadata in readable format. You can manage data view according to your needs, changing size and appearance of each element in report.

Reports made of metadata

Source of report data is database objects' metadata.

Tools for working with such reports:

HTML Report wizard

This tool allows you to generate a detailed HTML report of the selected database objects. HTML Report is a bunch of *.html files.

btnPrintMetadata Print metadata

Use this tool to print metadata of an object. The report can be saved to an external file: for this purpose use the btnPreviewExport Export drop-down list when in preview mode.

Note: Print metadata can be used to backup database structure, as it saves object's DDL.

See also:

Work with Data Reports


Edit Report

Report can be edited in the several ways:

  1. HTML report can be modified by means of external programs which support editing of HTML files.
  2. Select the Tools | btnPrintMetadata Print Metadata item of the main menu, then mark the needed objects and define printing settings and click the btnPrintPreview Preview button on the navigation bar or toolbar. In the opened Preview window click [image] Edit page to open page in the Report Designer.


Print Report

Report can be printed in several ways:

  1. HTML report can be printed by means of external programs which support printing of HTML files.
  2. Select the Tools | btnPrintMetadata Print Metadata item of the main menu, then mark the needed objects and define printing settings and click the btnPrintPreview Preview button on the navigation bar or toolbar. In the opened Preview window click [image] Print.


Update SQL Manager

SQL Manager for PostgreSQL can be updated in the following ways:

  1. Download executable file from the download page, then extract archive to the preferable directory (e.g. c:\unzipped). Close SQL Manager for PostgreSQL if it's opened and replace existing files in the SQL Manager for PostgreSQL directory with ones from archive.
  2. Select the Help | SQL Manager 2011 Direct, then press the Update button. If new SQL Manager for PostgreSQL version is released it will be offered for downloading. Click Yes in the dialog window to update SQL Manager for PostgreSQL automatically.


Managing users and roles

Create user

  1. Select the Tools | User Manager item of the main menu, then use the iconAddUser Add User item of navigation bar, toolbar or context menu and define necessary settings in the opened editor.
  2. Select the Tools | Grant Manager item of the main menu, then use the iconAddUser Add User item of navigation bar, toolbar or context menu and define necessary settings in the opened editor.

Create role

  1. Select the Tools | User Manager item of the main menu, then use the iconAddUser Add User item of navigation bar, toolbar or context menu and disable the Can Login option in the opened editor.
  2. Select the Tools | User Manager item of the main menu, then use the iconAddUser Add User item of navigation bar, toolbar or context menu and disable the Can Login option in the opened editor.

Edit user/role

User/role properties can be changed in editor.

You can open object in editor in the following ways:

  1. Select the Tools | User Manager item of the main menu, then use the iconEditUser Edit User item of navigation bar, toolbar or context menu and make needed changes in the opened editor.
  2. Select the Tools | Grant Manager item of the main menu, then use the iconEditUser Edit User item of navigation bar, toolbar or context menu and make needed changes in the opened editor.

Renaming user/role

Select the Tools | User Manager item of the main menu, then use the Rename User item of the context menu of the needed object.

Deleting user/role

User/role can be deleted in the following ways:

  1. Select the Tools | User Manager item of the context menu, then click the Delete user on the navigation bar, toolbar or context menu and confirm deletion in the opened dialog.
  2. Select the Tools | Grant Manager item of the context menu, then click the Delete user on the navigation bar, toolbar or context menu and confirm deletion in the opened dialog.


Granting permissions

Grant user permissions:

To check the rights already granted on specific object, or to grant new rights on it:

Open the object in the respective editor, then switch to the Permissions tab and define user permissions for the object.

Grant and edit user rights

Select the Tools | btnGrantManager Grant Manager item of the main menu, then pick the needed object in the Object name column (the easiest way to select an object is to use the drop-down list, which is located above the column)o. Select the user from respective drop-down list on the toolbar and define required user privileges on the object in the appropriate cell.

Note: Cells with actions which cannot be granted on the selected object are highlighted with grey.

Grant Manager window contains table, where rows are database object and columns are actions performed under objects.

To grant permissions on object select host, database and user by means of navigation bar and toolbar.

Permission on performing an action can be changed in three ways:

  • use cell context menu;
  • double-click a cell (after each value changing you will be asked to commit operation; note that value will be changed in the following order [image] Grant-> [image] Grant with GRANT OPTION-> [image] Revoke);
  • single-click active cell. This opens drop-down list with all available values.


Roles and Privileges

PostgreSQL manages database access permissions using the concept of roles. A role can be either a database user, or a group of database users.

Roles can own database objects and can assign privileges on those objects to other roles to control who has access to which objects. Furthermore, it is possible to grant membership in a role to another role, thus allowing the member role use of privileges assigned to the role it is a member of.

Note: In PostgreSQL versions before 8.1, users and groups were distinct kinds of entities, but now there are only roles. Any role can act as a user, a group, or both.

SQL Manager for PostgreSQL provides tools for efficient management of PostgreSQL database roles and privileges:

User Manager

Allows you to manage PostgreSQL users.

Group Manager

Allows you to manage PostgreSQL groups.

Role Editor

Allows you to create and edit PostgreSQL roles.

Grant Manager

Allows you to grant/revoke privileges on databases and database objects.

Adding Users

In order to add a new user/role:

  • select the Tools | User Manager main menu item or use the corresponding btnUserManager toolbar button to open User Manager;
  • select the Add user... item from the context menu or within the Navigation bar;
  • define user/role properties and permissions using Role Editor.

Editing User Properties

In order to edit an existing user/role:

  • select the Tools | User Manager main menu item or use the corresponding btnUserManager toolbar button to open User Manager;
  • select the Edit user... item from the context menu or within the Navigation bar;
  • edit the user/role properties and permissions using Role Editor.

Deleting Users

In order to delete an existing user/role:

  • select the Tools | User Manager main menu item or use the corresponding btnUserManager toolbar button to open User Manager;
  • right-click the user/role to delete and select the Delete User item from the context menu or within the Navigation bar;
  • confirm deleting in the dialog window.

Adding Groups

In order to add a new group:

  • select the Tools | Group Manager main menu item or use the corresponding btnGroupManager toolbar button to open Group Manager;
  • select the Add group... item from the context menu or within the Navigation bar;
  • define group properties and permissions using Role Editor.

Editing Group Properties

In order to edit an existing group:

  • select the Tools | Group Manager main menu item or use the corresponding btnGroupManager toolbar button to open Group Manager;
  • select the Edit group... item from the context menu or within the Navigation bar;
  • edit the group properties and permissions using Role Editor.

Deleting Groups

In order to delete an existing group:

  • select the Tools | Group Manager main menu item or use the corresponding btnGroupManager toolbar button to open Group Manager;
  • right-click the group to delete and select the Delete Group item from the context menu or within the Navigation bar;
  • confirm deleting in the dialog window.

Managing Privileges

To define grants on database objects:

  • select the Tools | Grant Manager main menu item, or use the corresponding btnGrantManager toolbar button to open Grant Manager;
  • select the object type using the drop-down list on the toolbar;
  • select a user or group from the Privileges for pane of the Navigation bar;
  • edit user/group privileges using Grant Manager

or

  • right-click an object in DB Explorer and select the Grants for <object_name> item from the context menu;
  • edit user/group privileges using Grant Manager.

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Tools

Services

Options

How To...


User Manager

The User Manager allows you to browse the list of existing PostgreSQL users and manage them efficiently.

To launch the tool, select the Tools | iconUserManager User Manager main menu item, or right-click the host alias in the DB Explorer tree and select the Tasks | iconUserManager Manage Users item from the context menu.

See also:

Group Manager

Role Editor

Grant Manager


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in User Manager.

User Manager - Using Navigation bar

The Navigation bar of the User Manager window allows you to:

General

iconHost select the host to retrieve the list of users

Actions

iconRefresh refresh the currently displayed list of users

iconAddUser call Role Editor to add a new user

iconEditUser call Role Editor to edit the selected user

iconDeleteUser delete the selected user

iconChangeOwner change owner of objects (for PostgreSQL 8.2 and higher)

iconAddGroup show/hide groups

iconRestoreDefaultSize restore the default size and position of the window

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Managing users

If you are not connected to the database server yet, select the host from the drop-down list on the Navigation bar to define connection settings.

The list displays the existing users as a grid with the following columns: User Name, System ID, Can Login, Superuser, Can Create DB, Can Create Role, Inherit, Connection Limit, Valid Until, Modify Catalog, User Count, Group Count.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

Right-click an item within the list to call the context menu allowing you to create a new user and specify its properties using Role Editor, edit, rename, delete the selected user, change (reassign) owner of objects (for PostgreSQL 8.2 and higher), show/hide groups, or show/hide columns of the list.

Users management tools are also available through the Navigation bar and toolbar of the User Manager.


Group Manager

The Group Manager allows you to browse the list of existing PostgreSQL groups and manage them efficiently.

To launch the tool, select the Tools | btnGroupManager Group Manager main menu item, or right-click the host alias in the DB Explorer tree and select the Tasks | btnGroupManager Manage Groups item from the context menu.

See also:

User Manager

Role Editor

Grant Manager


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Group Manager.

Group Manager - Using Navigation bar

General

iconHost select the host to retrieve the list of groups

Actions

iconRefresh refresh the currently displayed list of groups

iconAddGroup call Role Editor to add a new group

iconEditGroup call Role Editor to edit the selected group

iconDeleteGroup delete the selected group

iconChangeOwner change owner of objects (for PostgreSQL 8.2 and higher)

iconAddGroup show/hide users

iconRestoreDefaultSize restore the default size and position of the window

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Managing groups

If you are not connected to the database server yet, select the host from the drop-down list on the Navigation bar to define connection settings.

The list displays the existing groups as a grid with the following columns: Group, Object ID, Can Login, Superuser, Can Create DB, Can Create Role, Inherit, Connection Limit, Valid Until, Modify Catalog, User Count, Group Count.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

Right-click an item within the list to call the context menu allowing you to create a new group and specify its properties using Role Editor, edit, rename, delete the selected group, show/hide users, or show/hide columns of the list.

Groups management tools are also available through the Navigation bar and toolbar of the Group Manager.


Role Editor

Role Editor allows you to define user/group properties and membership. It opens automatically when you create a new user or group and is available on editing an existing one (see Create user, Edit user, Create Group, Edit Group for details).

To open a user or group in Role Editor, right-click it in the User Manager or Group Manager and select the Edit User.../Edit Group... context menu item.

  • Editing properties
  • Selecting role members
  • Defining user/group membership
  • Viewing DDL definition

See also:

User Manager

Group Manager

Grant Manager


Editing properties

Use the Properties tab of Role Editor to specify properties of the user/group being created/edited.

Name

Specifies the name by which the role is identified in the server.

Role Editor - Editing properties

Object ID

This field displays the OID of the role being created/edited. This value is read-only.

CheckBox Can login

This option specifies whether the role can be used to login (user) or not (role).

Password / Confirm password

Enter/confirm a password to identify the role.

Valid until

Check CheckBox Always if you do not want to restrict the role validity term, or set the role expiration date/time (i.e. the date and time after which the role's password is no longer valid) using the corresponding controls. It is possible to set the date value manually by typing it in, or using the date editor which is activated when you click the value box.

Connection limit

Specify how many concurrent connections the role can make (the default is -1 indicating that the number of connections is unlimited).

Role privileges

CheckBox Inherits rights from parent roles

This option determines whether the role inherits the privileges of role(s) it is a member of.

CheckBox Superuser

This option determines whether the role is a superuser, who can override all access restrictions within the database.

CheckBox Can create database objects

This option defines the role's ability to create database objects.

CheckBox Can create roles

This option determines whether the role will be permitted to create new roles (i.e. execute CREATE ROLE).

CheckBox Is a replication role

This option determines whether a role is allowed to initiate streaming replication or put the system in and out of backup mode.

CheckBox Can modify catalog directly

This option determines whether the role can modify system catalog directly or not.

Note: This option is only available if Superuser is specified for the role.


Selecting role members

The Members tab of Role Editor allows you to define which roles belong to the user/group, i.e. the existing roles which are automatically added as members of the role being created/edited.

Role Editor - Selecting members

To select a role, you need to move it from the Available roles list to the Selected roles list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the roles from one list to another.


Defining user/group membership

The Member of tab of Role Editor allows you to define user/group membership by selecting the role(s) the user/group will belong to (i.e. to which the user/group will be immediately added as a new member). The selected roles determine the tasks that can be performed through the user or group.

Role Editor - Defining membership

To select a role, you need to move it from the Available roles list to the Selected roles list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the roles from one list to another.


Grant Manager

Grant Manager allows you to set the user access grants on certain databases and database objects: schemas, tables, views, functions, sequences, languages, tablespaces, etc. Granting privileges on the selected database objects allows a user to perform the defined operation over the objects.

To open Grant Manager, select the Tools | btnGrantManager Grant Manager main menu item.

  • Using Navigation bar, Toolbar and context menu
  • Managing database-specific privileges
  • Filtering objects in list

See also:

User Manager

Group Manager

Role Editor


Using Navigation bar, Toolbar and context menu

The Navigation bar, Toolbar and context menu provide quick access to tools implemented in Grant Manager.

Grant Manager - Using Navigation bar

Database

iconDB select a database for grants management

General

iconRefresh refresh the content of the window

iconAddUser call Role Editor to add a new user

iconEditUser call Role Editor to edit an existing user

iconDeleteUser delete a database user

iconAddGroup call Role Editor to add a new group

iconEditGroup call Role Editor to edit a new group

iconDeleteGroup delete a group

iconExtractRolesGrant extract selected role's grants

iconExtractAllRolesGrants extract all roles' grants

iconShowGroups / iconHideGroups show/hide groups in the list

iconRestoreDefaultSize restore the default size and position of the window

Privileges for

btnGroupManager select an existing database user/group to grant privileges to

Right-click an item within the Privileges for list to call the context menu allowing you to:

  • call Role Editor to add a new user;
  • call Role Editor to edit the selected user;
  • delete the selected user;
  • call Role Editor to add a new group;
  • call Role Editor to edit the selected group;
  • delete the selected group.

NB: You can enable\disable Toolbars and Navigation bars at Environment options.

The context menu is aimed at facilitating your work: you can perform a variety of operations using context menu items.

The context menu of Grant Manager allows you to:

  • grant a permission on an object to the selected role;
  • grant a permission (with Grant Option) on an object to the selected role;
  • revoke a previously granted permission;
  • grant all permissions on an object to the selected role;
  • grant all permissions (with Grant Option) on an object to the selected role;
  • revoke all previously granted permissions on an object;
  • grant a permission on all objects to the selected role;
  • grant a permission (with Grant Option) on all objects to the selected role;
  • revoke a previously granted permission on all objects;
  • apply sorting of objects in grid (by type, name, schema);
  • apply sorting of objects in grid (by name, schema);
  • apply sorting of objects in grid (by type, schema, name);
  • apply sorting of objects in grid (by schema, name).

Grant Manager - Using context menu

See also:

Managing database-specific privileges

Filtering objects in list


Managing database-specific privileges

This window allows you to define privileges on database objects and grant privileges to a user or group.

To edit the privileges of a user/group on an object of a database, select the database using the Database pane of the Navigation bar, then select a user or group from the Privileges for list available within the Navigation bar or toolbar. Then select the type of objects to be displayed in the main working window using the drop-down list at the top.

The Object Name column contains the list of objects of the selected type; each subsequent column corresponds to the permission which can be granted on the selected object:

OWN, SEL, INS, UPD, DEL, RULE, REF, TRIG (for tables, views);

SEL, UPD, USG (for sequences);

OWN, EXEC (for functions);

OWN, CRT, USG (for schemas);

USG (for languages);

OWN, CRT (for tablespaces);

OWN, CONN, CRT, TMP, TRUN (starting from server version 8.4) (for databases).

Grant Manager - Managing database-specific privileges

The list of objects can be configured in several ways: you can specify that only granted objects are displayed in the grid, or define an object name to filter the objects by that name.

Right-click a cell to grant a specific permission on a certain object. To grant a permission on an object, you should find the object in the Object Name list and the column with the corresponding permission. Note that the cells that are highlighted gray do not admit to setting grants for an obvious reason (e.g. you cannot execute a table). The context menu of a cell contains possible permissions that can be granted:

Grant

Grant with Grant Option

Revoke (removes a previously granted permission)

Grant All

Grant All with Grant Option

Revoke All

Grant on All

Grant on All with Grant Option

Revoke on All

Note: When the Grant on all / Grant on All with Grant Option / Revoke on All items are used, the OWN privilege can be granted/revoked on all objects except databases. OWN privileges on databases should be assigned separately.

Hint: You can also assign privileges by double-clicking the respective cell - in this case the grant status is changed in the following order: Grant -> Grant with Grant Option -> Revoke.

The Column permissions of role <role_name> on table/view <table_name> area displays the grid with table/view columns and the privileges that can be granted to the selected role.

Use items of the context menu to grant/deny/revoke permissions on columns.

Grant Manager - Managing column permissions

If permissions on a column have been defined (for a table or view), the corresponding permission cell of the table/view contains a specific icon iconHasGrantedColumn .

See also:

Using Navigation bar, Toolbar and context menu

Filtering objects in list


Filtering objects in list

In large databases with huge amount of objects it may be difficult to find the required object. For this purpose you are provided with several tools for filtering objects in list:

  • the Object type control: select the required object type from the drop-down list (e.g. Tables);
  • the Filter panel: enter a character string to filter the object names by that string (note that the filter is case-sensitive);
  • the CheckBox Granted only option: check this option to display objects with at least one granted operation.

Grant Manager - Filtering objects in list

See also:

Using Navigation bar, Toolbar and context menu

Managing database-specific privileges


Services

SQL Manager for PostgreSQL provides graphical interface for a number of database maintenance operations. The following services are available in SQL Manager:

Analyze Tables

Collects statistics about the contents of tables in the database.

Vacuum Tables

Reclaims storage occupied by deleted tuples.

Reindex

Allows you to rebuild corrupted indexes.

Download Files

Allows you to save and load files directly to/from the server machine.

Database Statistics

A tool for browsing and reporting information about database activity.

Backup Database Wizard

A tool for creating database backups.

Restore Database Wizard

A tool for restoring databases from previously created backups.

Compare Databases Wizard

Creates an SQL Script providing databases synchronization.

Instance Manager

A tool for checking PostgreSQL service status.

Server status

Provides a convenient Server Status viewer.

Server logs

Provides a convenient Server Log SQL Parser.

Server Configuration

Provides a convenient Server Configuration manager.

Extensions

A tool for managing extensions which are packages that contain multiple SQL objects.

Using templates

Facilitates using SQL Manager wizards.

To obtain detailed information concerning specific PostgreSQL database maintenance services, refer to the official PostgreSQL server documentation.

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Database Tools

Options

How To...


Analyze Tables

Analyze Tables Wizard collects statistics about the contents of tables in the database, and stores the results in the system table pg_statistic (with PostgreSQL routines used). Subsequently, the query planner uses these statistics to help determine the most efficient execution plans for queries.

Note that Analyze Tables service is only available for the versions of PostgreSQL server 7.2 and higher.

To run the wizard, select the Services | [image] Analyze Tables... main menu item, or right-click the database alias in the DB Explorer tree and select the Tasks | [image] Analyze Tables... item from the context menu.

  • Selecting database
  • Selecting tables for analysis
  • Analyzing tables

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Vacuum Tables

Reindex

Database Statistics

Tables

Using templates


Selecting database

This step of the wizard allows you to specify the host and the database where tables for analysis are stored.

Analyze Tables - Selecting database

Host (7.2 or higher)

Use the drop-down list of registered hosts to select the host where the database resides.

Database

Use the drop-down list of registered databases to select the database where tables for analysis are stored.

CheckBox Show detailed operation report

Check this option to receive a detailed activity report for each analyzed table (VERBOSE).

Click the Next button to proceed to the Selecting tables to be analyzed step of the wizard.


Selecting tables to be analyzed

Use this step of the wizard to select the tables to be analyzed using PostgreSQL routines.

To select a table, you need to move it from the Available list to the Selected list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the tables from one list to another.

You can also enable the CheckBox All Tables option to select all available tables automatically.

Analyze Tables - Selecting tables to be analyzed

When you are done, click the Next button to proceed to the Analyzing tables step of the wizard.


Analyzing tables

This step of the wizard is intended to inform you that all necessary options have been set, and you can start the analyze tables process.

The Operations tab allows you to view the log of operations and errors (if any).

Analyze Tables - Analyzing tables

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed.

If necessary, you can save a template for future use.

Click the Run button to complete the operation.


Vacuum Tables

Vacuum Tables Wizard reclaims storage occupied by deleted tuples (with PostgreSQL routines used).

In normal PostgreSQL operation, tuples that are deleted or obsolete due to an update are not physically removed from their table; they remain present until a VACUUM is done. Therefore it is necessary perform this operation periodically, especially on frequently updated tables.

To run the wizard, select the Services | [image] Vacuum Tables... main menu item, or right-click the database alias in the DB Explorer tree and select the Tasks | [image] Vacuum Tables... item from the context menu.

  • Selecting database
  • Setting vacuum parameters
  • Selecting tables
  • Vacuuming tables

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Analyze Tables

Reindex

Tables

Using templates


Selecting database

This step of the wizard allows you to specify the host and the database where tables for vacuuming are stored.

Vacuum Tables - Selecting database

Host

Use the drop-down list of registered hosts to select the host where the database resides.

Database

Use the drop-down list of registered databases to select the database where tables for vacuuming are stored.

Click the Next button to proceed to the Setting vacuum parameters step of the wizard.


Setting vacuum parameters

This step of the wizard allows you to specify basic vacuum parameters to be applied to the VACUUM operation.

Vacuum Tables - Setting vacuum parameters

CheckBox Show detailed operation report

Check this option to receive a detailed vacuum activity report for each table (VERBOSE).

CheckBox Update optimization statistics

This option updates statistics used by the optimizer to determine the most efficient way to execute a query (ANALYZE).

CheckBox Compact unused space

This option specifies "full" vacuum which may reclaim more space, but takes much longer and exclusively locks the table (FULL).

CheckBox Freeze tuples

This option enforces "freezing" of tuples (FREEZE). This option is recommended for read-only databases.

Click the Next button to proceed to the Selecting tables step of the wizard.


Selecting tables

Use this step of the wizard to select the tables to be vacuumed using PostgreSQL routines.

To select a table, you need to move it from the Available list to the Selected list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the tables from one list to another.

You can also enable the CheckBox All Tables option to select all available tables automatically.

Vacuum Tables - Selecting tables

If necessary, you can save a template for future use.

When you are done, click the Next button to proceed to the Vacuuming tables step of the wizard.


Vacuuming tables

This step of the wizard is intended to inform you that all necessary options have been set, and you can start the vacuum tables process.

The Operations tab allows you to view the log of operations and errors (if any).

Vacuum Tables - Vacuuming tables

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed.

If necessary, you can save a template for future use.

Click the Run button to complete the operation.


Reindex

Reindex wizard allows you to rebuild corrupted indexes (with PostgreSQL routines used).

In some cases it is worthwhile rebuilding indexes periodically. Also, the contrib/reindexdb routine which can reindex an entire database. However, PostgreSQL has substantially reduced the need for this activity as compared to earlier releases.

To run the wizard, select the Services | [image] Reindex... main menu item, or right-click the database alias in the DB Explorer tree and select the Tasks | [image] Reindex ... item from the context menu.

  • Selecting database
  • Setting reindex options
  • Selecting objects to reindex
  • Reindexing objects

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Analyze Tables

Using templates

Tables

Indexes


Selecting database

This step of the wizard allows you to specify the host and the database where objects for reindex are stored.

Reindex - Selecting database

Host

Use the drop-down list of registered hosts to select the host where the database resides.

Database

Use the drop-down list of registered databases to select the database where objects for reindex are stored.

Click the Next button to proceed to the Setting reindex options step of the wizard.


Setting reindex options

This step of the wizard allows you to set up basic options pertaining to the reindex operation.

Select the reindex target:

RadioButton Index

Specifies Index as the reindex target object. If selected, you will have to specify the index table using the Table box, and select index(-es) in the appropriate boxes at the next step of the wizard.

RadioButton Table

Specifies Table as the reindex target object. If selected, you will have to select the table(s) at the next step of the wizard.

RadioButton All system indices

Specifies that all system indexes of the selected database should be reindexed. If selected, you will be immediately forwarded to the Reindexing objects step upon pressing the Next button.

RadioButton All indices

Specifies that all indexes of the selected database should be reindexed. If selected, you will be immediately forwarded to the Reindexing objects step upon pressing the Next button.

Reindex - Setting reindex options

Click the Next button to proceed to the Selecting objects to reindex step, or to the Reindexing objects step of the wizard if you have specified to reindex All system indices or All indices.


Selecting objects to reindex

Use this step of the wizard to select the objects to be reindexed using PostgreSQL routines.

Note that this step is only available if RadioButton Index or RadioButton Table was specified when setting reindex options.

To select an object, you need to move it from the Available Objects list to the Selected Objects list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the objects from one list to another.

Reindex - Selecting objects to reindex

When you are done, click the Next button to proceed to the Reindexing objects step of the wizard.


Reindexing objects

This step of the wizard is intended to inform you that all necessary options have been set, and you can start the reindex process.

The Operations tab allows you to view the log of operations and errors (if any).

Reindex - Reindexing objects

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed.

If necessary, you can save a template for future use.

Click the Run button to run the reindex object service.


Download Files

Download File wizard allows you to save and load files directly to/from the server machine.

In most cases loading data is performed considerably faster with the help of this wizard, especially when dealing with large files, due to using native server file access functions.

To run the wizard, select the Services | [image] Download Files... main menu item.

  • Selecting download method
  • Selecting database
  • FTP/SFTP connection setup
  • Specifying operation and selecting files

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Extensions

Using templates


Selecting download method

At this step you should select the download method which will be used for transferring files.

Select the preferable download method:

RadioButton PostgreSQL server functions

With the native PostgreSQL server file access functions used, files transfer is performed considerably faster in most cases.

RadioButton FTP

Specifies that the FTP method will be used for the file transfer operation.

RadioButton SFTP

Specifies that the SecureFTP method will be used for the file transfer operation.

Download File wizard - Selecting download method

Depending on whether you have selected the RadioButton PostgreSQL server functions or RadioButton FTP / RadioButton SFTP download methods, upon pressing the Next button you will either proceed to the Selecting database step, or you will be immediately forwarded to the FTP/SFTP connection setup step of the wizard.


Selecting database

This step of the wizard allows you to specify the database to copy files.

Note that this step is only available if the RadioButton PostgreSQL server functions method was specified when selecting download method.

Download File wizard - Selecting database

Database

Use the drop-down list of registered databases to select the database for copying files.

Click the Next button to proceed to the Specifying operation and selecting files step of the wizard.


FTP/SFTP connection setup

Use this step of the wizard to specify FTP/SFTP connection parameters.

Note that this step is only available if the RadioButton FTP or RadioButton SFTP method was specified when selecting download method.

Enter valid connection settings in the corresponding fields: Host, Port, User name, Password.

Download File wizard - Connection setup

Once you have specified the connection parameters, you can check whether it is possible to establish connection to the server: click the Test Connection button for this purpose. If connection is successful, you will get the 'Connected!' message; otherwise an error message will be returned.

Click the Next button to proceed to the Specifying operation and selecting files step of the wizard.


Specifying operation and selecting files

At this step you need to specify the desired operation and define the source and destination files.

Select the operation to be performed:

RadioButton Load file from server

RadioButton Save file to server

Download File wizard - Specifying operation and selecting files

Source

Type in or use the ExplorerButton button to specify the path and name of the source file.

Download File wizard - PostgreSQL server files

Destination

Type in or use the btnSaveAs Save as... button to specify the path and name of the destination file.

CheckBox Rewrite existing file

If this option is selected, existing destination files are replaced with the corresponding source files.

CheckBox Do not close wizard after copying

If this option is deselected, the wizard will be closed automatically when the process is completed.

Click the Finish button to run the file transfer operation.


Database Statistics

The Database Statistics service is intended for browsing and reporting information about database activity.

Using the service, you can get count of accesses to tables and indexes. PostgreSQL also supports determining the exact command currently being executed by other server processes. Since collection of statistics adds some overhead to query execution, the system can be configured to collect or not collect information. This is controlled by configuration parameters that can easily can be set up with the help of the corresponding item of the Navigation bar.

To open the Database Statistics window, select the Services | [image] Database Statistics main menu item, or right-click the database alias in the DB Explorer tree and select the Tasks | [image] Database Statistics item from the context menu.

  • Using Navigation bar and Toolbar
  • Diagram view
  • Browsing Object Statistics
  • Browsing Column Statistics
  • Browsing Database Statistics
  • Saving/loading statistics
  • Statistics Collector options

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Analyze Tables

Reindex


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Database Statistics.

Database Statistics - Using Navigation bar

Database

iconDB select a database for collecting statistics

General

iconRefresh refresh the content of the active tab

iconPrint print the content of the active tab

iconSaveToFile save the statistics to an external file or memory

iconLoadFromFile load statistics from an external file or memory

compare current statistics data with data of an existing one

iconProperties set Statistics Collector options

reset current statistics

iconRestoreDefaultSize restore the default size and position of the window

Depending on the current tab selection, the Navigation bar expands to one or more additional panes with tab-specific actions that can be useful for working with statistics data:

Object

Tick select the type of objects to collect statistics for (Tables, Indices, Sequences)

Tick select whether all statistics, query statistics, data change statistics or cache statistics should be collected

Tick select whether All objects, User objects only or System objects only should be displayed

Diagram Options

Tick specify the number of objects to be displayed in the diagram

Tick select the diagram criterion: Most frequent table scans (sequential and index), Number of scans, Updates, Inserts, Deletes, Most changed tables, Cache efficiency (for tables); Most frequently used indices, Most frequent scans, Cache efficiency (for indexes); Most frequent scans (for sequences).

NB: You can enable\disable Toolbars and Navigation bars at Environment options.

See also:

Diagram view

Browsing Object Statistics

Browsing Column Statistics

Browsing Database Statistics

Saving/loading statistics

Statistics Collector options


Browsing Column Statistics

The Column Statistics tab displays statistical data about the contents of the database, as well as statistical data about the values of index expressions. Note that all the statistical data is inherently approximate, even assuming that it is up-to-date.

Database Statistics - Browsing Field Statistics

The list displays fields as a grid with the following columns:

Schema, Table, Column, NULL Fraction, Average Width, Distinct, Correlation, Most Common Values, Most Common Frequency, Histogram Bounds.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

See also:

Using Navigation bar and Toolbar

Diagram view

Browsing Object Statistics

Browsing Database Statistics

Saving/loading statistics

Statistics Collector options


Diagram view

The Diagram View tab allows you to view object statistics as a diagram. To activate this type of statistics data view, select the Diagram View tab on the View mode panel at the bottom of the working area of the window.

Database Statistics - Diagram view

Use the Object Group pane of the Navigation bar to select the type of objects to collect statistics for (Tables, Indices, Sequences), and whether All objects, User objects only or System objects only should be displayed.

Use the Diagram Options pane of the Navigation bar to specify common diagram options:

Object count

Use the spinner control to specify the number of objects to be displayed in the diagram.

Use the drop-down list below to select the diagram criterion:

Most frequent table scans (sequential and index), Number of scans, Updates, Inserts, Deletes, Most changed tables, Cache efficiency (for tables);

Most frequently used indices, Most frequent scans, Cache efficiency (for indexes);

Most frequent scans (for sequences).

See also:

Using Navigation bar and Toolbar

Browsing Object Statistics

Browsing Column Statistics

Browsing Database Statistics

Saving/loading statistics

Statistics Collector options


Browsing Object Statistics

The Object Statistics tab of the Database Statistics window displays statistics for each object of the specified type (table, index, sequence) in the current database.

The list displays the existing database objects as a grid with the following columns:

Schema, Table, OID, Sequential Scans, Row Reads by Sequential Scans, Index Scans, Rows Fetched by Index Scans, Rows Inserted, Rows Updated, Rows Deleted, Block Reads from Disk, Block Reads from Cache, Index Block Reads from Disk, Index Block Reads from Cache, Toast Block Reads from Disk, Toast Block Reads from Cache, Toast Index Block Reads from Disk, Toast Index Block Reads from Cache, Live Rows Read, Dead Rows Read (for tables);

Schema, Table, Index, OID, Index Scans, Index Tuple Reads, Index Tuple Fetches, Index Block Reads from Disk, Index Block Reads from Cache (for indexes);

Schema, Sequence, OID, Block Reads from Disk, Block Reads from Cache (for sequences).

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

Statistics data can be also represented as a diagram. See Diagram view for more information.

Database Statistics - Browsing Object Statistics

Use the Object Group pane of the Navigation bar to select the type of objects to collect statistics for (Tables, Indices, Sequences), and whether All objects, User objects only or System objects only should be displayed.

The status bar at the bottom of the window displays type of statistics being currently displayed and the date/time they were collected.

See also:

Using Navigation bar and Toolbar

Diagram view

Browsing Column Statistics

Browsing Database Statistics

Saving/loading statistics

Statistics Collector options


Browsing Database Statistics

The Database Statistics tab displays statistical data about the specified server databases.

Database Statistics - Browsing Database Statistics

The list displays databases as a grid with the following columns:

OID, Database, Number of Active Server Processes, Committed Transactions, Rolled Back Transactions, Total Disk Block Reads, Total Number of Buffer Hits, Rows Returned, Rows Fetched, Rows Inserted, Rows Updated, Rows Deleted.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

Background writer statistics

This area is available for PostgreSQL 8.3. The following parameters pertaining to the selected database are available: Number of scheduled checkpoints, Requested checkpoints, Buffers written by checkpoints, Buffers cleaning scans, Number of times the background writer stopped a cleaning scan, Buffers written by backends, Total buffers allocated.

See also:

Using Navigation bar and Toolbar

Diagram view

Browsing Object Statistics

Browsing Column Statistics

Saving/loading statistics

Statistics Collector options


Saving/loading statistics

Use the btnSave Save statistics and the ExplorerButton Load statistics items of the Navigation bar to save the statistical data as an external file for future use or to memory, and to load the previously saved statistics data.

You are able to save the statistics to an external *.dbs file for future use, or to memory. Loading the data is performed in the same way.

Database Statistics - Loading statistics

Moreover, you can compare the current statistics data with statistical data that were saved to a file or is stored in memory. In this case the differences will be displayed in the grid.

See also:

Using Navigation bar and Toolbar

Diagram view

Browsing Object Statistics

Browsing Field Statistics

Browsing Database Statistics

Statistics Collector options


Statistics Collector options

In order to set the configuration parameters for collecting statistics, please select the Statistics collector options item of the Navigation bar.

Database Statistics - Statistics Collector options

See also:

Using Navigation bar and Toolbar

Diagram view

Browsing Object Statistics

Browsing Field Statistics

Browsing Database Statistics

Saving/loading statistics


Backup Database

Backup Database Wizard allows you to perform the database backup operation on your PostgreSQL system (with the pg_dump utility of PostgreSQL server used).

This operation is used to create a backup copy of a single database, an entire database cluster, roles and/or tablespaces.

To run the wizard, select the Services | [image] Backup Database... main menu item, or right-click the database alias in the DB Explorer tree and select the Tasks | [image] Backup Database... item of the context menu. Alternatively, you can right-click the host alias and select the Tasks | [image] Backup Database... context menu item.

  • Selecting host
  • Specifying objects to backup
  • Setting output format and file name
  • Setting backup options for database objects
  • Selecting objects to be included
  • Selecting objects to be excluded
  • Setting additional backup options
  • Running database backup

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Copy Database Wizard

Restore Database

Using templates


Selecting host

This step of the wizard allows you to specify the host where the database for backup resides, and to provide authentication parameters.

Backup Database - Selecting host

Host

Use the drop-down list to select the host where the database resides.

User name / Password

Specify valid user name and password to access the selected host.

Click the Next button to proceed to the Specifying objects to backup step of the wizard.


Specifying SSH tunneling parameters

This step appears only if you are performing backup operation of the database connected via SSH tunnel.

Here you are to specify the necessary parameters for connection with SSH tunneling used.

Specify SSH host name, SSH port, SSH user name, SSH password, the path to the SSH key file (if necessary) in the corresponding boxes.

See SSH connection properties for details.

Backup database - Specifying tunneling parameters

Click the Next button to proceed to the Specifying objects to backup step of the wizard.


Specifying objects to backup

This step of the wizard allows you to specify server objects for the database backup operation.

Backup Database - Specifying objects to backup

Server version

This label displays the current PostgreSQL server version.

Output script for server version

Use the drop-down list to select the version of PostgreSQL server for the backup script. The output script will be generated in compliance with the specifications of the selected server version: 9.3, 9.2, 9.1, 9.0, 8.4, 8.3, 8.2, 8.1, 8.0 or 7.4.

Backup target

Use this group to define the backup target:

RadioButton Single database (use the Source database drop-down list to select the database you need)

RadioButton Entire database cluster

RadioButton Roles only

RadioButton Tablespaces only

RadioButton Both roles and tablespaces

Click the Next button to proceed to the Setting output format and file name step of the wizard.


Setting output format and file name

This step allows you to specify the output format and output file properties.

Backup Database - Setting output format and file name

Output format

Use this group to define the output format (Note: This group is only available if you selected Single database as the backup target at the previous step):

RadioButton Plain-text SQL script

RadioButton Compressed plain-text SQL script

RadioButton Custom pg_dump archive

RadioButton Tar archive

Output file name

Set a name for the result file and type in or use the btnSaveAs Save as... button to specify the path to this file on your local machine or on a machine in the LAN.

CheckBox Add date and time into file name

Check this option to add the current timestamp to the generated backup file name.

File encoding

If necessary, use the drop-down list to select the encoding to be applied to the output file.

Click the Next button to proceed to the Setting backup options for database objects step of the wizard.


Setting backup options for database objects

Use this step of the wizard to specify objects to backup and structure/data options (if available).

Backup Database - Setting backup options for database objects

Objects to backup

Use this group to specify whether all or specified objects are to be backed up:

RadioButton All objects of the database

RadioButton Specified schemas

RadioButton Specified tables

Structure/data options

Use this group to specify whether structure and/or data are to be backed up (Note: This group is only available if you selected Plain-text SQL script as the output format at the previous step):

RadioButton Backup both structure and data

RadioButton Backup structure only

RadioButton Backup data only

Depending on whether you have selected to backup Specified schemas / Specified tables or All objects of the database, upon pressing the Next button you will either proceed to the next step of the wizard, or you will be immediately forwarded to the Setting additional backup options step of the wizard.


Selecting objects to be included

Use this step of the wizard to specify objects to be included into the backup operation.

Backup Database - Selecting objects to be included

To select an object, you need to move it from the Available Objects list to the Selected Objects list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the objects from one list to another.

If necessary, you can select objects by mask: click the Add Name Mask button and specify a string in the Add Object Name Mask dialog.

Backup Database - Selecting objects to be included - Mask

Click the Next button to proceed to the Selecting objects to be excluded step of the wizard.


Selecting objects to be excluded

Use this step of the wizard to specify objects to be excluded from the backup operation.

Backup Database - Selecting objects to be excluded

To select an object, you need to move it from the Available Objects list to the Selected Objects list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the objects from one list to another.

If necessary, you can select objects by mask: click the Add Name Mask button and specify a string in the Add Object Name Mask dialog.

Backup Database - Selecting objects to be excluded - Mask

Click the Next button to proceed to the Setting additional backup options step of the wizard.


Setting additional backup options

This step offers some additional options that may be useful for the database backup operation.

Backup Database - Setting additional backup options

Structure options

CheckBox Add create database command

If this option is selected, the CREATE DATABASE statement will be included into the backup script.

CheckBox Add drop object commands

If this option is selected, the DROP statements will be added for database objects.

CheckBox Don't use $ quoting

This option disables dollar-quoting in the backup script.

CheckBox No privileges

This option disables privilege allocation for database objects in the script.

CheckBox Don't set object ownership

This option disables object ownership statements for database objects in the script.

CheckBox Use set session authorization

If this option is selected, the currently set session authorization is used.

Data options

Specify the method that will be used to backup data.

RadioButton Data as COPY statements

RadioButton Data as INSERT statements

CheckBox Disable triggers

Select this option to disable triggers for the backup session.

CheckBox Dump table OIDs

If this option is selected, table OIDs (object identifiers) will be dumped as well.

CheckBox INSERT with column names

If this option is selected, column names will be included into the INSERT statements.

Advanced options

CheckBox Compress file

If this option is selected, the backup file will be compressed to the extent specified using the Compress level control.

CheckBox Dump BLOBs

If this option is selected, BLOBs (binary large objects) will be dumped as well.

CheckBox No setting tablespace commands

With this option, all objects will be created in whichever tablespace is the default during restore.

Compress level

This control allows you to set the compression level for the backup file. Move the slider between the 0 and 9 threshold values to select the required compression level value within this scope.

When you are done, click the Next button to proceed to the next step of the wizard.


Setting backup creation options

This step of the wizard is available only when Output script for server version option value is set to 8.4 at the Specifying objects to backup step.

Use this step to manage dump creation options:

Role to be used to create the dump

This drop-down list allows you to define role that will be used to dump the database.

Table lock timeout, milliseconds (0- unlimited wait)

Within this increment field you can restrict time to lock a table in milliseconds. By default it is set "0", that is used for to unlimited wait.

Backup Database - Setting backup creation options

When you are done, click the Next button to proceed to the last step of the wizard.


Running database backup

This step of the wizard is intended to inform you that all necessary options have been set, and you can start the backup database process.

The log area allows you to view the log of operations and errors (if any).

Backup Database - Running database backup

CheckBox Verbose mode

This option specifies verbose mode, i.e. detailed object comments, start/stop times and progress messages to standard error will be written to the dump file and displayed in the log area.

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed.

If necessary, you can save a template for future use.

Click the Run button to run the backup database operation.


Restore Database

Restore Database Wizard allows you to perform the database restore operation on your PostgreSQL system (with the pg_restore utility of PostgreSQL server used).

This operation is used to rebuild a damaged or corrupted database that has been backed up using Backup Database Wizard. You can restore the backup copy to an existing database, or create a new database and restore the backup copy into the newly created database.

To run the wizard, select the Services | [image] Restore Database... main menu item, or right-click the database alias in the DB Explorer tree and select the Tasks | [image] Restore Database... item of the context menu. Alternatively, you can right-click the host alias and select the Tasks | [image] Restore Database... context menu item.

  • Selecting host
  • Selecting source file for restoring
  • Selecting restore type
  • Setting restore options for database objects
  • Selecting objects to restore
  • Setting additional restore options
  • Running database restore

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.

See also:

Backup Database

Using templates


Selecting host

This step of the wizard allows you to specify the host to restore database onto, and to provide authentication parameters.

Restore Database - Selecting host

Host

Use the drop-down list to select the host to restore database onto.

User name / Password

Specify valid user name and password to access the selected host.

Click the Next button to proceed to the Selecting source file for restoring step of the wizard.


Specifying SSH tunneling parameters

This step appears only if you are performing restore operation of the database connected via SSH tunnel.

Here you are to specify the necessary parameters for connection with SSH tunneling used.

Specify SSH host name, SSH port, SSH user name, SSH password, the path to the SSH key file (if necessary) in the corresponding boxes.

See SSH connection properties for details.

Restore database - Specifying tunneling parameters

Click the Next button to proceed to the Selecting source file for restoring step of the wizard.


Selecting source file for restoring

This step of the wizard allows you to specify the source dump file for the database restore operation.

Restore Database - Selecting source file for restoring

Source dump file

This control allows you to specify the source dump file for the restore operation. Depending on the specified backup file format, you should select a *sql, *.dmp or *.tar file using the ExplorerButton Explorer button.

Click the Next button to proceed to the Selecting restore type step of the wizard.

Note: If you are restoring data from a plain-text SQL script, before you proceed to the next step, you will be offered to specify encoding for the dump script.


Script conversion

Before you proceed to the Selecting restore type step, you can specify encoding for the dump script using the Script Conversion dialog.

Select the required encoding:

RadioButton Windows default

RadioButton Database default (disabled in this case)

RadioButton Other encoding (use the list on the right to select the encoding you need)

The Preview area allows you to browse the text of the dump script with the selected encoding applied, and edit the script text, if necessary.

Restore Database - Selecting source file for restoring - Script conversion

Click OK to apply current settings and proceed to the Selecting restore type step of the wizard.


Selecting restore type

At this step of the wizard you need to select restoring type. Note that the set of available options depends on the source dump file format and PostgreSQL version.

Restore Database - Selecting restore type - From SQL script

When restoring from a plain-text SQL script, set the following options:

RadioButton Restore into existing database

Specifies that the backup copy will be restored into an existing database.

Database name

Use the drop-down list to select the database into which the backup script will be restored.

RadioButton Create a new database and restore into it

Specifies that a new database will be created, and the backup copy will be restored into this database.

Database name

Enter a name for the new database to be created.

Database template

Use the drop-down list to select the database that will be used as a template for the new database.

Database encoding

Use the drop-down list to select the encoding to be applied to the new database.

CheckBox Ignore any CREATE DATABASE and \connect statements

If this option is selected, the CREATE DATABASE and \connect statements will be ignored while processing the backup archive.

CheckBox Stop if connecting to multiple databases

If this option is selected, the restore operation will be stopped in case multiple database connections are detected.

Restore Database - Selecting restore type - From pg_dump archive

When restoring from a pg_dump archive or a Tar archive, set the following options:

RadioButton Restore into existing database

Specifies that the backup copy will be restored into an existing database.

Database name

Use the drop-down list to select the database into which the dump archive will be restored.

CheckBox Drop database objects before recreating

Select this option to drop objects from the database before restoring.

RadioButton Create a new database and restore into it

Specifies that a new database will be created, and the backup copy will be restored into this database.

Database name

Enter a name for the new database to be created.

Database template

Use the drop-down list to select the database that will be used as a template for the new database.

Database encoding

Use the drop-down list to select the encoding to be applied to the new database.

RadioButton Create the database that is specified in the dump and restore into it

The application will create the database that is specified in the dump archive, and the backup copy will be restored into this database.

CheckBox Drop the database if it exists

Select this option to drop the existing database (if any).

Click the Next button to proceed to the Setting restore options for database objects step of the wizard.


Setting restore options for database objects

Use this step of the wizard to specify objects to restore and structure/data options.

Note: This step is available if you restore database from a pg_dump archive or a tar archive.

Restore Database - Setting restore options for database objects

Objects to restore

Use this group to specify whether all or specified objects are to be restored:

RadioButton Restore all objects

RadioButton Restore specified objects

RadioButton Restore objects from list file

List file

This box allows you to specify a file containing the list of objects to be restored. Type in or use the Explorer ExplorerButton button to specify the path to this file on your local machine or on a machine in the LAN. If necessary, you can Generate and Edit this file using the corresponding buttons.

Structure/data options

Use this group to specify whether structure and/or data are to be restored:

RadioButton Restore both structure and data

RadioButton Restore structure only

RadioButton Restore data only

Depending on whether you have selected to Restore specified objects or Restore all objects / Restore objects from list file, upon pressing the Next button you will either proceed to the next step of the wizard, or you will be immediately forwarded to the Setting additional restore options step of the wizard.


Selecting objects to restore

Use this step of the wizard to specify objects to be restored.

Note: This step is available if you restore database from a pg_dump archive or a tar archive.

Restore Database - Selecting objects to restore

RadioButton Restore entire schemas

Adds all objects of a schema to the restore operation.

RadioButton Restore specified objects

Adds only selected objects of specified type to the restore operation.

Object type

Use the drop-down list to select the type of objects to be restored.

To select an object, you need to move it from the Available Objects list to the Selected Objects list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the objects from one list to another.

If necessary, you can change the objects order: use the [image] [image] buttons or drag-and-drop operations within the Selected Objects list.

Click the Next button to proceed to the Setting additional restore options step of the wizard.


Setting additional restore options

This step allows you to set additional options that will be used to restore the database. Note that the set of available options depends on the source dump file format and PostgreSQL version.

Restore Database - Setting restore options

Structure options

CheckBox No privileges

This option disables privilege allocation for database objects during the restore operation.

CheckBox Don't set object ownership

This option disables object ownership statements for database objects during the restore operation.

CheckBox Use set session authorization statements

If this option is selected, the currently set session authorization is used (available if the Don't set object ownership option is deselected).

CheckBox Ignore settings tablespace commands

With this option, all objects will be created in whichever tablespace is the default during restore.

CheckBox Use IF EXISTS clause

Add IF EXISTS clause to metadata operations if applied.

Data options

CheckBox No data for failed tables

If this option is selected, table data will not be restored for the tables whose metadata failed to restore.

Advanced options

CheckBox Stop restoring on error

If this option is selected, the restore operation will be stopped when an error occurs.

CheckBox Restore in single transaction

This option specifies restoring within a single transaction.

Click the Next button to proceed to the next step of the wizard.


Setting restore process options

This step is available when you restore a PostgreSQL 8.4 database from a '.tar' or '.dmp' file.

Role to be used to perform the restore

Use this option to define the role that will be used to perform the restore operation.

Number of jobs

This option indicates the amount of threads used for the restore operation.

Restore Database - Setting restore process options

When you are done, click the Next button to proceed to the last step of the wizard.


Running database restore

This step of the wizard is intended to inform you that all necessary options have been set, and you can start the restore database process.

The log area allows you to view the log of operations and errors (if any).

Restore Database - Running database restore

CheckBox Verbose mode

This option specifies verbose mode, i.e. detailed object comments, start/stop times and progress messages to standard error will be displayed in the log area.

CheckBox Close the Wizard after successful completion

If this option is selected, the wizard is closed automatically when the process is completed.

If necessary, you can save a template for future use.

Click the Run button to run the restore database operation.


Instance Manager

This tool allows you to check PostgreSQL service status, to stop or start it. To launch this tool use the Services | Instance Manager item of main menu.

You can manage server instance by using navigation bar.

To shut down/startup the instance click the Stop/Start Service button. Be aware that all users connected to the databases will be disconnected.

Log messages

This log shows all messages during server startup and shutdown.

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.


Using Navigation and Toolbar Bar

The Navigation bar and Toolbar provide quick access to tools implemented in Instance Manager.

Instance Manager - Using Navigation Bar

The Navigation bar of the Instance Manager window allows you to:

Select server from the Host drop-down list;

Select Service from the corresponding drop-down list;

btnExecuteQuery Start service;

btnStopRecordMacro Stop service;

iconRefresh Refresh - get actual statistics.

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Server Status

The Server Status viewer allows you to get common information on current connections to the server, locks, prepared transactions, and to view server log files.

To open the Server Status viewer window, select the Services | iconServerStatus Server Status main menu item, or right-click the host alias in the DB Explorer tree and select the Tasks | iconServerStatus Server Status item from the context menu.

Note: Retrieving server status information is only available on PostgreSQL 7.4 and above.

  • Using Navigation bar and Toolbar
  • Viewing Connections
  • Viewing Locks
  • Managing Prepared Transactions
  • Viewing Logfile

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Server Status.

Server Status - Using Navigation bar

The Navigation bar of Server Status allows you to:

Servers

Select the registered server to view information about.

Refresh Rate

Type in or use the spinner controls to define the refresh periodicity (in seconds).

Log Date (on Logfile tab only)

Use the drop-down list to select the date for displaying logs.

General

iconRefresh refresh the content of the active tab

iconCancelExecution cancel execution

iconChange Management - History rotate log (view the current log)

btnEnvironmentOptions view log options

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Viewing Connections

The Connections tab of the Server Status viewer is intended for viewing the current connections to each database on the specified host, the users, processes and other connection information.

Note: If you are not connected to the database server yet, select the host from the drop-down list on the Navigation bar to define connection settings.

Server Status - Viewing Connections

The list displays the connections as a grid with the following columns: PID, Database, User, Client Address, Application Name, Query Start, Query, Process Start. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Right-click an item within the list to call the context menu allowing you to refresh the list or cancel execution of a query.

Connections view tools are also available through the Navigation bar and Toolbar of the Server Status viewer. Using the Navigation bar and toolbar you can also set the Refresh Rate for the connection list.

See also:

Locks

Prepared Transactions

Logfile


Viewing Locks

The Locks tab of the Server Status viewer displays the current locks outstanding in the PostgreSQL Lock Manager. This information can be useful when attempting to debug or track down deadlocks on your server.

Server Status - Viewing Locks

The list displays the locks as a grid with the following columns: PID, Database, Relation, User, Transaction, Access Mode, Granted, Query Start, Query. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Right-click an item within the list to call the context menu allowing you to refresh the list or cancel execution of a query.

Locks view tools are also available through the Navigation bar of the Server Status viewer. Using the Navigation bar you can also set the Refresh Rate for the lock list.

See also:

Connections

Prepared Transactions

Logfile


Managing Prepared Transactions

The Prepared Transactions tab of the Server Status viewer allows you to browse the list of outstanding prepared transactions. Prepared transactions are an aspect of Two Phase Commit (2PC), used in distributed transaction managers. Normally, prepared transactions are handled by the transaction manager. In case of a failure, it might be necessary to commit or rollback a transaction manually; use the Commit transaction or Rollback transaction items on the general bar to do that.

Note: This tab is only available for running PostgreSQL server version 8.1 or higher.

Server Status - Managing Prepared Transactions

The list displays the prepared transactions as a grid with the following columns: Transaction, Global ID, Prepare Time, Owner, Database. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Right-click an item within the list to call the context menu allowing you to refresh the list or commit/rollback a transaction.

Transaction management tools are also available through the Navigation bar of the Server Status viewer. Using the Navigation bar you can also set the Refresh Rate for the transactions list.

See also:

Connections

Locks

Logfile


Viewing Logfile

The Connections tab of the Server Status viewer lists server log files, if configured in postgresql.conf (redirect_stderr = true, log_destination='stderr' and log_filename='postgresql-%Y-%m-%d_%H%M%S.log'). SQL Manager will also extract a time stamp from the logfile in a separate column, if the log_line_prefix is configured accordingly.

Note: This tab is only available for running PostgreSQL server version 8.1 or higher.

Server Status - Viewing Logfile

The list displays the log entries as a grid with the following columns: Time, Level, Entry. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Right-click an item within the list to call the context menu allowing you to refresh the list or rotate the selected log (i.e. start logging to a new log file).

Log management tools are also available through the Navigation bar of the Server Status viewer. Using the Navigation bar you can also set the Refresh Rate for the Logfile list, or filter the list by a time stamp using the Log Date drop-down list.

If necessary, you can configure Log Options using the corresponding item of the Navigation bar.

Server Status - Viewing Logfile - Log options

Select the CheckBox Enable SQL logging parameter (log_statement) option and specify which SQL statements will be logged:

RadioButton none (don't log SQL statements)

RadioButton DDL (logs all data definition commands)

RadioButton mod (logs all DDL and data-modifying statements: INSERT, UPDATE, DELETE, etc.)

RadioButton all (logs all SQL statements)

See also:

Connections

Locks

Prepared Transactions


Server Log SQL Parser

Server Log SQL Parser allows you to analyze PostgreSQL server logs in a simple way providing the ability to sort, filter and group log statements.

To launch the tool, select the Services | Server Log SQL Parser main menu item.

  • Using Navigation bar and Toolbar
  • Working with Server Log SQL Parser

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.


Using Navigation bar and Toolbar

The Navigation bar and Toolbar provide quick access to tools implemented in Server Log SQL Parser.

Server Log SQL Parser - Using Navigation bar

The Navigation bar of Server Log SQL Parser allows you to:

General

iconLoadFromFile open an external server log file

iconLoadLogFileFromServer load a log file from server using Download File Wizard

open a log entry in Query Data

open a log entry in Design Query

iconCopyToClipboard copy the selected log entry to clipboard

iconRestoreDefaultSize restore the default size and position of the window

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Working with Server Log SQL Parser

The Server Log SQL Parser window displays the list of server logs as a grid, and allows you to manage them efficiently.

Server Log SQL Parser - Working with Server Log SQL Parser

Only logs containing SQL statements can be opened in Server Log SQL Parser. In order SQL statements to be logged to server logs you need to set the following parameters in PostgreSQL configuration file:

  • log_statement = 'all'
  • logging_collector = on
  • log_min_duration_statement = 0

The list displays the server logs as a grid with the following columns: Pid, Duration, Time, Statement, Error, Warning. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

Right-click an item within the list to call the context menu allowing you to open a log in Query Data and copy the selected log to Windows clipboard.

Server logs management tools are also available through the Navigation bar of Server Log SQL Parser.

For your convenience several navigation and filtering facilities are implemented: you can navigate and filter log entries in grid using the corresponding buttons below. For details see Filtering records.

The lower area displays the full statement for the currently selected log entry.

For your convenience the Grouped tab of the Server Log SQL Parser provides all statements grouped by the template. That is the default grouping and you can change it if you want.

Server Log SQL Parser - Working with Server Log SQL Parser - Grouped


Server Configuration

SQL Manager for PostgreSQL provides a useful and effective service - the ability to view and change server configuration. There are many configuration parameters that affect the behavior of the database system which can be set up via Server Configuration manager.

Using the tabs of the Server Configuration manager you can view/edit a number of server parameters and options which can be changed to optimize PostgreSQL server performance.

To launch the tool, select the Services | [image] Server Configuration main menu item, or right-click the host alias in the DB Explorer tree and select the [image] Server Configuration item from the context menu.

  • Viewing Parameters
  • Modifying Role Settings
  • Setting up Configuration Files
  • Changing Host-Based Authentication File
  • Changing Ident File

Availability:
Full version (for Windows) | Yes
Lite version (for Windows) | No
Note: To compare all features of the Full and the Lite versions of SQL Manager, refer to the Feature Matrix page.


Viewing Parameters

The Parameter List tab of the Server Configuration manager allows you to view current parameters of your PostgreSQL. It displays a number of configuration parameters that affect the behavior of the database system. To obtain more information on specific parameters, refer to PostgreSQL documentation.

Note: If you are not connected to the database server yet, select the host from the drop-down list on the Navigation bar to define connection settings.

Server Configuration - Viewing Parameters

The Parameter List displays the parameters as a grid with the following columns: Parameter Name, Value, Short Description, Extra Description, Context, Type, Source, Minimum, Maximum, Parameter Group. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

Note: Only parameters with "user" or "superuser" values of the Context field can be redefined.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Right-click an item within the list to call the context menu allowing you to refresh the list.

See also:

Modifying Role Settings

Setting up Configuration Files

Changing Host-Based Authentication File

Changing Ident File


Modifying Role Settings

The Role Settings tab of the Server Configuration manager provides the ability to define specific server parameters for a role according to your needs. To obtain more information on specific parameters, refer to PostgreSQL documentation.

Use the Roles pane on the Navigation bar to select the PostgreSQL role.

Server Configuration - Modifying Role Settings

The Role Settings list displays the parameters as a grid with the following columns: Parameter Name, Role Setting. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Right-click an item within the list to call the context menu allowing you to refresh the list, add/edit/remove a parameter, copy parameters from one role to another, delete all parameters, save the settings.

Role tools are also available through the Navigation bar of the Server Configuration manager.

See also:

Viewing Parameters

Setting up Configuration Files

Changing Host-Based Authentication File

Changing Ident File


Setting up Configuration Files

The Configuration File tab of the Server Configuration manager allows you to edit parameters set starting and run-time parameters.

Common PostgreSQL configuration information is typically stored in postgresql.conf file. Each parameter can be edited and enabled for the database system to take effect. To obtain more information on specific parameters, refer to PostgreSQL documentation.

Server Configuration - Setting up Configuration Files

The Configuration File displays the configuration parameters as a grid with the following columns: Enabled, Parameter Name, Parameter Setting, Current Setting. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Right-click an item within the list to call the context menu allowing you to refresh the list, edit a parameter, or save current settings.

Configuration file management tools are also available through the Navigation bar of the Server Configuration manager.

The Edit Parameter dialog allows you to change the parameter name, set its value, browse parameter info and supply a description, if necessary.

Server Configuration - Setting up Configuration Files - Edit parameter

See also:

Viewing Parameters

Modifying Role Settings

Changing Host-Based Authentication File

Changing Ident File


Changing HBA File

The Host-Based Authentication File tab of the Server Configuration manager allows you to set parameters for Host-Based authentication.

In addition to the postgresql.conf file already mentioned, PostgreSQL uses two other configuration files which control client authentication - pg_hba.conf and pg_ident.conf. Each parameter can be edited and enabled for the database system to take effect. To obtain more information on specific parameters, refer to PostgreSQL documentation.

Server Configuration - Changing HBA File

The Host-Based Authentication File list displays the parameters as a grid with the following columns: Enabled, Delete, Type, Database, User, Address, Crypt Method, Option. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Right-click an item within the list to call the context menu allowing you to refresh the list, add/edit a connection, or save current settings.

With the help of General bar you can Add or Edit selected connections; to edit an existing connection simply double-click it.

Server Configuration - Changing HBA File - Edit client authentication

Type

local

This record matches connection attempts using Unix-domain sockets.

host

This record matches connection attempts made using TCP/IP. Host records match either SSL or non-SSL connection attempts.

hostssl

This record matches connection attempts made using TCP/IP, but only when the connection is made with SSL encryption.

hostnossl

This record type has the opposite logic to hostssl: it only matches connection attempts made over TCP/IP that do not use SSL.

Database

Specifies which database names this record matches.

User

Specifies which database role names this record matches.

Address

Specifies the client machine IP address range that this record matches.

Method

Specifies the authentication method to use when connecting via this record.

trust

Allow the connection unconditionally. This method allows anyone that can connect to the PostgreSQL database server to login as any PostgreSQL user they like, without the need for a password.

reject

Reject the connection unconditionally. This is useful for "filtering out" certain hosts from a group.

md5

Require the client to supply an MD5-encrypted password for authentication.

crypt

Require the client to supply a crypt()-encrypted password for authentication.

Note: this option is recommended only for communicating with pre-7.2 clients.

password

Require the client to supply an unencrypted password for authentication.

krb5

Use Kerberos V5 to authenticate the user. This is only available for TCP/IP connections.

ident

Obtain the operating system user name of the client and check if the user is allowed to connect as the requested database user by consulting the map specified after the ident key word.

pam

Authenticate using the Pluggable Authentication Modules (PAM) service provided by the operating system.

To obtain more information on specific parameters, refer to PostgreSQL documentation.

See also:

Viewing Parameters

Modifying Role Settings

Setting up Configuration Files

Changing Ident File


Changing Ident File

The Ident File tab of the Server Configuration manager allows you to configure ident-based authentication.

In addition to the postgresql.conf file already mentioned, PostgreSQL uses two other configuration files which control client authentication - pg_hba.conf and pg_ident.conf. Each parameter can be edited and enabled for the database system to take effect. To obtain more information on specific parameters, refer to PostgreSQL documentation.

Using of Ident method on editing client authentication means to obtain the operating system user name of the client (for TCP/IP connections by contacting the ident server on the client, for local connections by getting it from the operating system) and check if the user is allowed to connect as the requested database user by consulting the map specified after the ident key word.

When using ident-based authentication, after having determined the name of the operating system user that initiated the connection, PostgreSQL checks whether that user is allowed to connect as the database user he is requesting to connect as. This is controlled by the ident map argument that follows the ident key word in the pg_hba.conf file.

Server Configuration - Changing Ident File

The Ident File displays the parameters as a grid with the following columns: Enabled, Delete, Map Name, Ident Name (OS Name), Role Name. If more convenient, you can change the order of the columns by dragging their headers horizontally.

Click a column caption to sort items by values of this column in the ascending or the descending mode.

If necessary, you can group the data in grid by any of the columns. This operation is performed by dragging the column header to the gray "Group by" box area at the top. When grouping by a column is applied to the grid, all the rows are displayed as subnodes to the grouping row value. To reverse grouping, just drag the column header back.

Right-click an item within the list to call the context menu allowing you to refresh the list, add/edit map, or save current settings.

See also:

Viewing Parameters

Modifying Role Settings

Setting up Configuration Files

Changing Host-Based Authentication File


Extensions

Extensions are packages, which contain multiple SQL objects.

An extension to PostgreSQL typically includes multiple SQL objects: a new data type will require new functions, new operators, and probably new index operator classes. It is convenient to collect all these objects into a single package to simplify database management.

This tool is available only for Postgres SQL Server ver. 9.1 and above.

To open the Extensions window, select the Services | [image] Database Extensions main menu item, or right-click the database alias in the DB Explorer tree and select the Tasks | [image] Database Extensions item from the context menu.

All available extensions are displayed in this dialog.

You can manage server extensions by using navigation bar or context menu.

Extension properties:

Extension Name

Default version

Installed

Installed version

Object Schema

Relocatable

Owner

Description

Config Tables


Using Navigation and Toolbar Bar

The Navigation bar and Toolbar provide quick access to tools implemented in Extensions.

Database Extensions - Using Navigation bar

Database

iconDB select a database for extension installing

General

iconRefresh Refresh the extensions list

iconCommit Install selected extension This item is only available for non-installed extensions.

Update to new version

iconCross Uninstall selected extension

  • Relocate to another schema

NB: You can enable\disable Toolbars and Navigation bars at Environment options.


Install/Update Extensions

On Install/Update of the extension the following dialog is open.

Extension name is a name of the extension to install.

Version to install

CheckBox Default version - default version of the extension wil be installed

Version name - if you need another version of this extension select it from the drop down list. The Default version options is supposed to be unchecked.

Need superuser to install

Relocatable to other schema

Required schema - name of the schema that the extension must be installed into.

Prerequisite extensions - names of prerequisite extensions.

Schema to install objects to

CheckBox Default schema for current user. This option is available when you are installing the extension.

CheckBox Move objects to another schema. This option is available when you are updating the extension.

Schema name

To install the extension to schema different from the default user scheme select it from this drop down list.


Options

SQL Manager for PostgreSQL provides you with capabilities for flexible personalization of the application.

Please see the chapters below to learn how to use personalization tools effectively.

  • Environment Options
  • Editor Options
  • Save Settings
  • Localization
  • Keyboard Templates
  • Object Templates
  • Find Option dialog

The Options menu allows you to export all program settings to a *.reg file for future use, e.g. when you need to move the settings to another machine (see Save Settings for details).

Hint: Each of the SQL Manager Options dialogs is provided with the Reset to defaults button. You can use it either to Reset current category or to Reset all categories.

See also:

Getting Started

Database Explorer

Database Management

Database Objects Management

Change Management

Query Management Tools

Data Management

Import/Export Tools

Database Tools

Services

How To...


Environment Options

Environment Options allow you to customize general options of the SQL Manager application.

To open the Environment Options window, select the Options | Environment Options... main menu item, or use the Environment Options btnEnvironmentOptions button on the main toolbar.

Preferences

Full mode activation

Confirmations

Appearance

Tools

Timeouts

DB Explorer

Search

Object Editors

Query Data

SQL Monitor

Execute Script

Design Query

Style & Color

Database Designer

Print Metadata

Data Export

Fonts

Grid

Data Options

Print Data

Color & Formats

Advanced

Column Options

Localization

Global Shortcuts

Find Option

See also:

Editor Options

Save Settings


Preferences

CheckBox Show splash screen at startup

Displays the splash screen of SQL Manager for PostgreSQL at the application startup.

CheckBox Restore desktop on connect

This option determines whether the previously opened windows and their positions should be restored upon connection to the database.

CheckBox Do not restore if 'Refresh objects on connection' database registration option is off

Check this option to perform restoring desktop operation if the 'Refresh objects on connection' option of the Database registration info is on.

CheckBox Disable multiple instances

Checking this option prevents one from running multiple instances of SQL Manager for PostgreSQL.

CheckBox Show desktop panel (for MDI Environment style only)

Displays Desktop Panel when no child windows are open.

CheckBox Show Full Version features

This option is available in the Lite version of SQL Manager. When selected, a 30-day period of fully-functional usage is activated.

Environment Options - Preferences

If necessary, you can reset all toolbars and menus of the application using the corresponding button.

Hint: The Reset to Defaults button which is common for all sections of the Environment Options dialog opens a menu with items allowing you to discard all changes and reset options of the current category or of all categories to their defaults.


Full mode activation

Note that when using the FREE Lite version of SQL Manager for PostgreSQL (which contains functional limitations) you can activate a 30-day period of fully-functional usage. During this period you will get the splash screen displaying the number of days left every time you start the application. After the period expires, you will be able to continue using the Lite version.

Environment Options - Full mode activation

To activate the 30-day Full version mode, please enable the CheckBox Show Full Version features option available on the Preferences page of the Environment Options dialog (note that this option is only available in the Lite version of SQL Manager).


Confirmations

CheckBox Confirm saving the object (or document) upon closing the editor

If this option is selected, the program requires confirmation each time you want to save changes in a database object or document.

CheckBox Confirm dropping of object

If this option is selected, the program requires confirmation of dropping a database object.

CheckBox Confirm exit from SQL Manager

If this option is selected, you are prompted for confirmation each time when you exit the application.

Environment Options - Confirmations

CheckBox Confirm deleting records

This option enables/disables a confirmation dialog for deleting records.

CheckBox Confirm metadata changing (Changing Metadata Window)

This option enables/disables the Changing Metadata window.

CheckBox Confirm addition into spell checking dictionary

Enable this option if you wish to be prompted for adding a word to the dictionary which is used for checking words spelling (see Spell Checking).

CheckBox Confirm transformation of misprint into substitution

If this option is selected, you need to confirm replacing a misprinted word with a corresponding substitution word (see Spell Checking).

CheckBox Confirm transaction commit

If this option is selected, the program requires confirmation on attempt to commit a transaction.

CheckBox Confirm transaction rollback

If this option is selected, the program requires confirmation on attempt to rollback a transaction.

CheckBox Confirm transaction commit on closing data in object editors

If this option is selected, the program prompts to commit the transaction upon closing the 'Data' tab in object editors.

Transaction confirmation in Query Data and Design Query

CheckBox Disable transaction confirmation on closing the editor

If this option is checked, no transaction confirmation will be required on closing Query Data and Design Query.

Default action on closing the editor

Specify the default action (Commit or Rollback) and this action will be performed automatically each time when you exit Design Query or Query Data.

Table altering operations performed via recreation

This option defines SQL Manager for PostgreSQL behavior when it is necessary to recreate a table to perform requested changes over it:

Enabled - such operations will be performed without warnings;

Enabled, show warning - the warning window will appear if an operation requires table recreation;

Disabled - denies operations of this type.


Windows

Theme

Select the main color theme for the application: Light, Blue or Dark.

Environment style

This group allows you to define the basic window environment - RadioButton MDI (like Microsoft® Office) or RadioButton Floating windows (like Borland® Delphi IDE).

Windows restrictions

This option allows you to set the number of editors (Table Editor, SQL Query etc.) that can be opened simultaneously.

Zoom options

This group of options is only available if Environment Style is set to Floating windows environment. It allows you to set maximization size for child windows:

RadioButton Full screen

RadioButton Restricted by Main Form

RadioButton Restricted by Main Form and DB Explorer

RadioButton Justified my Main Form and DB Explorer

Environment Options - Windows

Bar style for child forms

Here you can define the location of action buttons: RadioButton within the Navigation bar (on the left) and/or RadioButton on the Toolbar.

If necessary, you can also CheckBox Enable floating toolbars for your application.


Tools

CheckBox Show only connected databases in drop-down menu

If this option is checked, only connected databases are displayed in drop-down menus of such tools as Design Query, Execute Script, etc.

CheckBox Allow using parameters in query text

This feature allows you to specify different values within a query in a popup dialog just before the query execution.

You can set the character to specify a parameter within the query in the Parameter sign char field.

CheckBox Use transactions in Data tab of object editors, Query Data and Design Query*

If this option is enabled, a transaction is active until the 'Data' tab is closed or the 'Commit' button is pressed; all edited records are blocked until the transaction is committed. If this option is disabled, the transaction starts and is immediately committed (autocommit) on saving each record which is blocked only for a short period of time.

Environment Options - Tools

CheckBox Asynchronous query execution*

Check this option to allow executing queries in background mode (asynchronously).

CheckBox Use separate connection for each data view within a database*

Uncheck this option to use separate connection for each data view within a database. Note that this option is only available when the Use transactions in Data tab of object editors, Query Data and Design Query option is enabled.

CheckBox Convert line end to Linux style in string constants of executed SQL statements

Check this option to transform all the multi-line literals to Linux-like form, using one-byte line breaking term.

New tool form should be opened for

This option defines which database should be selected in the launched tool.

RadioButton Database currently selected in DB Explorer

Tool will be opened with the database focused in the DB Explorer selected.

RadioButton Database selected in currently focused form

Tool will be opened with the database which is selected in the current form.


Timeouts

This page allows you to set timeouts for some operations performed in SQL Manager. Timeouts are necessary for preventing program hang-up upon execution of a SQL statement due to transaction interlocking. You can set timeouts for changing metadata, recreating tables and data tabs.

Environment Options - Tools - Timeouts

Refresh of objects can also be terminated after timeout expiration if there is an active transaction that has made any changes to metadata.


DB Explorer

General options

CheckBox Show hosts in DB Explorer

Shows/hides database hosts in the DB Explorer tree.

CheckBox Show table subobjects

Shows/hides table subobjects (columns, indexes, etc.) in the DB Explorer tree.

CheckBox Sort by aliases

Use this option to apply sorting registered hosts and databases by their aliases in the DB Explorer tree.

CheckBox Rename objects by editing in place

Allows you to edit object names in DB Explorer by selecting any object and clicking its alias one more time.

CheckBox Refresh objects on showing in SQL Assistant

This option enables/disables refreshing objects each time they are displayed in SQL Assistant.

CheckBox Auto expand navigation pane

If this option is checked, the list of navigation tabs in DB Explorer is expanded automatically on program launch.

CheckBox Show hint

The option enables/disables hints for objects in the DB Explorer tree.

Environment Options - Tools - DB Explorer

Recent objects count

Defines the number of objects displayed within the Recent menu of the DB Explorer.

Function list appearance

This option defines appearance of functions in the DB Explorer tree.

RadioButton Show arguments list as part of function name

If selected, function nodes do not contain any child nodes and look like "function_name(argument_list)"

RadioButton Show arguments as child nodes

If selected, function nodes contain "Arguments" node, which contains argument nodes.

RadioButton Group functions by names

If selected, overloaded functions are grouped, having lists of arguments as child nodes.

Table details in SQL Assistant

These options switch the SQL Assistant mode for displaying table details (columns, indexes, Foreign keys, checks, triggers, rules, table info, description or definition).

Expand after connection

This group of options allows you to specify the node(s) indicating type(s) of objects that will be expanded within DB Explorer upon successful connection to the database.

See also:

Database Explorer


Search

Here you can set search options for DB Explorer search string:

Environment Options - Tools - DB Explorer - Search - String

Search options

CheckBox Search by categories

This option determines the search scope when the Find Item feature is used: if this option is selected, the search is performed within the currently selected category (node in the tree) only.

CheckBox Use case sensitive search

If this option is selected, the search string case is considered when using the Search Panel.

Environment Options - Tools - DB Explorer - Search

CheckBox Use Case Sensitive search

If this option is selected, the search string case is considered when using the Search Panel.

CheckBox Don't search in collapsed nodes

Enable the option to search within the expanded nodes only.

CheckBox Start-with search

Check this option to search for objects those names begin with the defined searched string.


Object Editors

All

CheckBox Convert created objects' names to lower case

Enable this option if you need to convert the names of all newly created objects to the lower case automatically.

CheckBox Show OWNER on DDL tab

With this option enabled OWNER statement is generated for the objects on the DDL tab, otherwise it's removed from the object definition.

CheckBox Always open the first tab

If this option is checked, the first tab is activated by default on opening an object in its editor.

Table editor

CheckBox Show Object Explorer

Enables/disables the Object Explorer panel within the Navigation bar of Table Editor.

CheckBox Do not retrieve record count for a table

Check this option to disable retrieving record count for tables (with this feature enabled, opening large tables may take much time).

CheckBox Serial columns as integer

With this option enabled, 'serial' type columns will be displayed as 'integer'.

Environment Options - Tools - Object Editors

Function editor

CheckBox Dollar-quoted function body on server 8.0 and higher

This option allows dollar-quoted function body definition.

CheckBox Split function options into several lines in DDL

Use this option to define whether to split function options into several lines in DDL or to display all options in one line.

CheckBox Execute with definer's privileges as default

This option specifies that the function is to be executed with the privileges of the user that created it. Otherwise, the function is to be executed with the privileges of the user that calls it. If this option is enabled then the CheckBox Execute with definer's privileges option in the Function Editor when creating a new function will be checked automatically.

Object list style

These options allow you to define the style of the combo-boxes used to select database objects (e.g. Table or view in Trigger Editor). Objects can be represented as a tree, a list sorted by namespace or a list sorted by name. Use the CheckBox Ignore case option to enable/disable case sensitive sorting.

See also:

Database Objects Management


Query Data

Query results

CheckBox Fetch all data

If this option is checked, all the records according to the SELECT query are extracted from the tables, otherwise - only those displayed within the Results tab of Query Data.

CheckBox Show result for each query

With this option checked, when you execute two or more queries, the result of each query will be displayed one by one. Otherwise, only the result of the last query will be displayed.

CheckBox Show results on Edit tab

If this option is checked, the Results tab is displayed as a separate tab.

Advanced

CheckBox Execute selected text separately

Check this option to allow execution of the selected statement separately.

CheckBox Write only successfully executed queries to database SQL log file

If this option is checked, unsuccessful queries will not be saved to the Query Data log file (see Setting log options in the Database Registration Info dialog).

CheckBox Don't save queries automatically for the next session

If this option is checked, the SQL query text will not be saved. Otherwise, it will be saved in Windows registry and will be therefore available in the next application sessions.

CheckBox Same queries for all databases

With this option enabled, Query Data stores all queries in a shared repository, so that switching to another database does not cause loading queries of that database (applying this option does not affect currently opened copies of Query Data). The value of the option can be changed freely without any risk to lose the query repository content.

CheckBox Refresh DB Explorer upon successful DDL statement execution

If this option is selected, the content of DB Explorer is refreshed each time a DDL statement is executed successfully in Query Data.

Environment Options - Tools - SQL Editor

Execution plan

CheckBox Explain query on execution

If this option is checked, the query plan is displayed automatically upon query execution in Query Data.

CheckBox Explain with verbose (showing execution plan as text only)

Check this option to display additional information regarding the plan. Specifically, include the output column list for each node in the plan tree, schema-qualify table and function names, always label variables in expressions with their range table alias, and always print the name of each trigger for which statistics are displayed.

CheckBox Explain with analyze

Check this option to show the full internal representation of the plan tree, rather than just a summary while displaying query plan.

CheckBox Explain buffer usage (PostgreSQL 9.0 and higher)

Check this option to include information on buffer usage. Specifically, include the number of shared blocks hits, reads, and writes, the number of local blocks hits, reads, and writes, and the number of temp blocks reads and writes.

CheckBox Display execution plan as text in addition to representation as schema

If this option is checked, the execution plan is represented both as a tree and text.

See also:

Query Data


SQL Monitor

Operations

Specify the operations to be logged in SQL Monitor: Connect, Start of transaction, Commit, Rollback, Execute query.

SQL log

This group of options allows you to enable logging of all SQL Monitor events to a file. Check the Log SQL Monitor events to file option, specify the path to the log file using the btnSaveAs button, and enter a name for the *.sql file. To clear the log file after it reaches some definite size, check the Clear log file when it is greater than... option and set the maximum file size (in Kilobytes).

Environment Options - Tools - SQL Monitor

CheckBox Show time of operation

If this option is checked, the execution time of logged operations is added.

CheckBox Always show on top

Select this option if you want to display the SQL Monitor window in the foreground permanently.

See also:

SQL Monitor


Execute Script

CheckBox Abort script execution on error

If this option is checked, script execution is aborted if an error occurs.

CheckBox Execute in transaction, rollback on error

This option is only available if the Abort script on error option is checked. This option evokes automatic rollback when script execution is aborted.

CheckBox Enable parsing

With this option checked, Execute Script Editor parses the loaded script to enable fast navigation in the Script Explorer tool.

CheckBox Show message when done

Displays a message box on finishing script execution.

CheckBox Execute selected text separately

Check this option to allow execution of the selected statement separately.

CheckBox Don't clear error list on selected text execution

If this option is checked, the error list is not cleared upon execution of the selected statement.

CheckBox Show notices in error list

Select this option to enable information messages when working with scripts.

CheckBox Register newly created databases

If the option is enabled, the Register Database dialog will appear when a database is created using Execute Script.

CheckBox Disable all code features in Execute Script

This option disables code completion, code folding, highlight and all options that are set on the Code completion page. For options that are set on the Color Scheme page, the defaults will be applied.

Environment Options - Tools - SQL Script

See also:

Execute Script Editor


Design Query

General options

CheckBox Allow SELECT queries only

When this option is checked, the INSERT, UPDATE and DELETE statements are not allowed in Design Query.

CheckBox Select condition row

Displays the selected condition in different rows on the Criteria and Grouping Criteria tabs of Design Query.

CheckBox Drag column name

Displays the dragged column name in the Builder area.

CheckBox Hide selection when inactive

Hides the selection when the Design Query window is inactive.

CheckBox Show columns types

Displays columns types additionally to their names.

CheckBox Union all by default

Check this option to use the UNION ALL expression in Design Query by default.

The UNION keyword allows you to include the results of two SELECT statements in one resulting table.

The ALL parameter incorporates all rows into the results, including duplicates. If not specified, duplicate rows are removed.

Environment Options - Tools - Query Builder

Visible tabs

These options specify which Design Query tabs are available and which are not. Use the check boxes to make the corresponding tabs visible/invisible.

Script format

These options specify case formatting of keywords and functions in query text within the Edit tab: As is keeps the original case, Uppercase sets all the keywords/functions to the upper case, Lowercase sets all the keywords/functions to the lower case, and First upper sets the first letters of all keywords/functions to the upper case.

Additionally, you can set styles and color for all Design Query objects by using Style & Color Palette.

See also:

Design Query


Style & Color

Style

These options specify the way various Design Query elements look: the Condition button: Flat, 3DLook, Raised; object borders: Bump, Etched, Raised, Sunken. If necessary, you can also specify flatness for objects and buttons using the corresponding options.

CheckBox Flat objects

This option sets the flat appearance of objects in Design Query.

CheckBox Windows style of tables

This option determines the appearance of tables in the Builder tab.

CheckBox Show icons on tabs

With this option selected, you can see icons next to the tab names in Design Query.

Environment Options - Tools - Query Builder - Style & Color

Color palette

These options define the colors of various Design Query elements.

Active condition row (at the Criteria and Grouping criteria tabs):

Environment Options - Tools - QB - Style & Color - Active condition row

Condition text (at the Criteria and Grouping criteria tabs):

Environment Options - Tools - QB - Style & Color - Condition text

Condition item text (at the Criteria and Grouping criteria tabs):

Environment Options - Tools - QB - Style & Color - Condition item text

Table client area (in the diagram area):

Environment Options - Tools - QB - Style & Color - Table client area

Active table caption (in the diagram area):

Environment Options - Tools - QB - Style & Color - Active table caption

Inactive table caption (in the diagram area):

Environment Options - Tools - QB - Style & Color - Inactive table caption

Column text (in the diagram area):

Environment Options - Tools - QB - Style & Color - Field text

Selected column text (in the diagram area):

Environment Options - Tools - QB - Style & Color - Selected field text

Work space (in the diagram area):

Environment Options - Tools - QB - Style & Color - Work space

Column (at the Criteria and Grouping criteria tabs):

Environment Options - Tools - QB - Style & Color - Field

Operation (at the Criteria and Grouping criteria tabs):

Environment Options - Tools - QB - Style & Color - Operation

Group (at the Grouping criteria tab):

Environment Options - Tools - QB - Style & Color - Group

Predicate (at the Criteria and Grouping criteria tabs when a subquery is used):

Environment Options - Tools - QB - Style & Color - Predicate

Subquery (at the Criteria and Grouping criteria tabs when a subquery is used):

Environment Options - Tools - QB - Style & Color - Subquery

Click an item to select a color for the corresponding element using the Color dialog where you can specify the required color from the palette.


Database Designer

CheckBox Automatically open last diagram file

With this option enabled the designer is opened with the last diagram edited.

Visual settings

Model notation

When you work in Database Designer, you can choose one of the following modeling notations:

  • Integration DEFinition for Information Modeling (IDEF1X);
  • Information Engineering (IE).

The IDEF1X and IE notations use different symbols to represent relationships between entities (and tables).

Environment Options - Tools - VDBD

CheckBox Draw PRIMARY KEY columns separately

Separates Primary key columns from other columns with a horizontal line.

Environment Options - Tools - VDBD - Draw PRIMARY KEY fields separately

CheckBox Draw entities icons

Displays icons at the left of each entity header according to its type.

Environment Options - Tools - VDBD - Draw entities icons

CheckBox Draw attributes icons

Displays icons at the left of each attribute according to its type (Primary key, Foreign key, ordinary column).

Environment Options - Tools - VDBD - Draw attributes icons

CheckBox Draw only names of entities

Displays only entity headers, columns are hidden.

Environment Options - Tools - VDBD - Draw only names of entities

CheckBox Draw FOREIGN KEY name

Displays foreign key names for the corresponding relations.

Environment Options - Tools - VDBD - Draw FOREIGN KEY name

CheckBox Draw attribute information

Display attribute properties (optionality, keys, etc.) in parentheses after the attribute name and type.

Environment Options - Tools - VDBD - Draw attributes information

CheckBox Draw page borders

Displays borders on the diagram page which are the borders used when printing pages with the diagram.

Grid options

CheckBox Show grid

Displays dots in the diagram area to make the grid visible.

CheckBox Snap to grid

Automatically aligns entities on the form with the nearest grid line. You cannot place an entity in between grid lines.

Grid size

Sets grid spacing in pixels along the x- and y-axes. Specify a higher number to increase grid spacing.

Entity header font

Select a font type and size to display entity headers.

Attributes font

Select a font type and size to display attributes.

Additionally, you can set color for all VDBD diagram objects using the Style and Color section.

This section allows you to customize the default appearance of the diagram.

Select a diagram element from the list:

Workspace

Selected item

Table

Relation

Column

Primary key

Unique column

Foreign key

Autoincrement column

Not null column

Comment

Work area

Environment Options - Tools - VDBD - Color Palette - Work area

Entity

Environment Options - Tools - VDBD - Color Palette - Entity

Entity caption text

Environment Options - Tools - VDBD - Color Palette - Entity caption text

Attribute text

Environment Options - Tools - VDBD - Color Palette - Attribute text

Selection

Environment Options - Tools - VDBD - Color Palette - Selection

Selected entity caption text

Environment Options - Tools - VDBD - Color Palette - Selected entity caption text

Selected attribute text

Environment Options - Tools - VDBD - Color Palette - Selected attribute text

Click an item to select a color for the corresponding element using the Color dialog where you can specify the required color from the palette.

See also:

Database Designer


Print Metadata

Default paper size

Define the default paper size for reports created with the Print Metadata tool used:

RadioButton A4 (210 x 297 mm)

RadioButton Letter (8 1/2 x 11 ")

Environment Options - Tools - Print Metadata

See also:

Print Metadata


Data Export

This page allows you to customize formats applied to exported data.

Environment Options - Tools - Data Export

Data formats

Edit the format masks to adjust the result format in the way you need: Integer format, Float format, Date format, Time format, DateTime format, Currency format, Boolean True, Boolean False, Null string.

CheckBox Auto save format strings

Select this option to save specified format strings automatically.

These settings can also be specified at the Adjusting data formats step of Export Data Wizard.

Fore more details see Format specifiers.

See also:

Export Data Wizard


Fonts

This section of the Environment Options dialog allows you to specify fonts used in the application.

The box below displays the sample text with the selected font applied.

Environment Options - Fonts

System font name

Defines the font used by SQL Manager for PostgreSQL. Select the font name from the drop-down list of available system fonts.

Environment Options - Fonts - System font name

System font size

Defines the font size used by SQL Manager for PostgreSQL. Type in or use the drop-down list to select the required value.

Grid font name

Defines the font used for displaying data in the Data Grid. Select the font name from the drop-down list of available system fonts.

Grid font size

Defines the font size used for displaying data in the Data Grid. Type in or use the drop-down list to select the required value.

In the sample grid you can view how the data grid will look like with the configured font.


Grid

General options

CheckBox Striped grids

Displays the odd grid rows in a different color defined by the Strip option available on the Color & Formats page.

CheckBox Show editor immediately

Allows editing the cell value right after the cell is clicked.

CheckBox Always show editor

Set this option to make the cell editors always active.

CheckBox Enable auto-search in grid

If this option is checked, the cursor is automatically forwarded to the closest match when you start typing.

CheckBox Row multi-selection

With this option set, multiple rows can be selected in grid.

CheckBox Invert selection

Determines whether a single cell within the focused row or the entire row is highlighted when focused.

CheckBox Column auto-width

With this option set, column widths are changed in order to display all columns without using the horizontal scroll bar. If the content a column is still too large to display without a need to resize the grid, then the column values are truncated and the hidden characters are replaced with an ellipsis at the end.

CheckBox Cell auto-height

If the widths of the columns are insufficient to display the full content, then text clipping occurs. Set this option to prevent this. If this option is set, the cell content is displayed in multiple lines where necessary. You can set the number of lines to display using the Cell max line count option.

Environment Options - Grid

Grid layout preference

RadioButton Autofit column widths

Use this option to shrink the grid columns so that the longest visible column value fits.

RadioButton Save and restore layout

Use this option to keep the original grid width. Check the Restore sorting option to apply defaults to sorting (except for SQL sorting) as well.

Root level options

These options are applied to the main view of the grid. See Grid View for details.

Detail level options

These options are applied to the detail view of the grid. See Grid View for details.

CheckBox Show "Group by" box

Displays the gray area above the column caption allowing one to group data in the grid.

CheckBox Show indicator

Activates/deactivates the row indicator pane at the left.

Environment Options - Grid - Show indicator

CheckBox Show navigator

Activates/deactivates the data navigator similar to the navigation pane at the top of the grid. The navigator is available at the bottom of detail level view.

Environment Options - Grid - Show navigator

CheckBox Show "New item row"

Displays an empty row at the bottom of a view which is a convenient way for adding data to the grid.

CheckBox Hide tabs for single detail

This option is useful when only one view is present on the detail level. When the option is enabled, the view tab is hidden.

Selection

If the RadioButton Row selection is selected then the whole record in the table is selected in the table on clicking the cell. Otherwise, only the clicked cell is selected ( RadioButton Cell selection option).

Check the CheckBox Row/cell multi-selection option to enable the selection of multiple cells or rows in the grid with the Shift button.

See also:

Grid View


Data Options

Limit options in table and view editors

Define the number of records to be selected on opening the Data tab of Table Editor and View Editor:

RadioButton Select all records from a table*

RadioButton Select only ... records* (you should set the number of records using the corresponding spinner control)

Advanced

CheckBox OID columns as BLOB*

Enable this option if you want the OID column to be displayed as a BLOB (OID - object ID - the object identifier of a row).

CheckBox TIMESTAMP columns as string

Use this option to select display of TIMESTAMP and TIMESTAMPTZ data.

Load visible rows mode if records more than...*

Set this option to switch to the Load visible rows mode when the number of records in the dataset exceeds the specified value.

String columns width (chars)

Using this option you can limit string columns width that may improve performance on large datasets.

Environment Options - Grid - Data Options

Locating record on update or delete

Specify the method of the WHERE clause generation for UPDATE and DELETE SQL statements:

RadioButton Use all columns

RadioButton Use key and changed columns

RadioButton Use key columns only

Default grid mode

RadioButton Load all rows*

The grid loads all records from a dataset. This option increases the grid performance by reloading only changed dataset records when updating. In this mode all features (automatic sorting, filtering and summary calculations) are available.

RadioButton Load visible rows*

The grid loads only a fixed number of dataset records into memory. This option minimizes dataset loading time. Automatic sorting, filtering, summary calculations are not available in this mode.

The Default grid mode options allow you to define the grid mode which will be used by default.

With the Load all rows option enabled, when loading data, all the records are loaded into grid buffers. In this mode opening the tables with many records may take a considerable amount of time. But in this case you can make use of some advantages: in the filter drop-down list the column headers are displayed with the values for quick filtering; it is possible to open several sub-levels at the same time when viewing data in master-detail view, etc.

In case opening and other operations with an object consisting of many records takes sufficient time, the Load visible rows mode should be used instead. It can be set individually for each table and saved between sessions (can be set through the context menu of the grid).

Note: Changing the options marked with the asterisk (*) sign does not affect the way data are viewed in currently opened windows. These options are used as default values for Data Options parameters for newly registered databases. To change the options for registered databases, please use the Database Registration Info dialog.

See also:

EMS SQL Manager FAQ


Print Data

Save/restore following print data properties

These options specify which Print Data properties will be saved between work sessions (e.g. if you tick off the Page settings item, those settings will be saved and stored between the sessions).

You can save/restore the following Print Data properties: Card view representation, Detail view representation, Expanding, Formatting, Level options, "On every page" options, Pagination, Preview options, Image options, Selection options, Report size options, Showing grid elements, Page number format, Page settings, Report title.

Environment Options - Grid - Print Data


Color & Formats

Display formats

Integer columns

Defines the format for displaying INTEGER columns.

Float columns

Defines the format for displaying NUMERIC and DOUBLE PRECISION columns.

Date / Time columns

Defines the format for displaying DATE / TIME columns.

For more information refer to the Format specifiers page.

Environment Options - Grid - Color & Formats

Colors

Options of this group allow you to set colors for basic grid elements. Use the ellipsis EllipsisButton button to open the Color dialog allowing you to select the required color from the palette.

Grid

Defines the background color of the data grid.

Row

Defines the color of the selected row in the data grid.

Strip

Defines the color of the odd rows (applied if the Striped grids option is set on the Grid page).

NULL values

Text

Defines the text that stands for NULL values in grid.

Font color

Defines the font color for displaying NULL values in the grid. Use the ellipsis EllipsisButton button to open the Color dialog allowing you to select the required color from the palette.


Advanced

Advanced options

CheckBox Cell hints for clipped text

Indicates whether a hint box is displayed when hovering over a cell containing clipped text.

CheckBox Focus cell on cycle

Determines whether the focus moves to the next row after it reaches the right-most cell within the current row.

CheckBox Focus first cell on new record

Determines whether the focus moves to the first cell of a newly created row.

CheckBox Next cell on pressing Enter

Determines whether the current view columns can be navigated by using the Enter key.

CheckBox Show navigator hints

Indicates whether a hint box is displayed when hovering over navigation buttons.

CheckBox MRU list in column filter

Enables showing of Most Recently Used items when filtering columns

Card width

Defines the width of the card used in Card View mode.

Environment Options - Grid - Advanced

Form view

CheckBox Large memo editor

Sets the number of lines for text-typed columns when viewing data in Form view.

CheckBox Word wrap in memo editor

Determines whether long strings are wrapped within the memo editor area.

CheckBox Word wrap in string editor

Determines whether long strings are wrapped within the string editor area.

Grid lines

Determines whether to display vertical and horizontal lines between cells.

Detail tabs position

Specifies the position of the tabs in detail level views: top or left.

Card layout direction

Specifies the direction of cards in Card View mode: horizontal or vertical.

Show edit buttons

Indicates when the edit buttons are displayed: never, for focused record or always.


Column Options

Common options

CheckBox Auto-select text

Determines whether all text within an editor is automatically selected when the editor gets focus.

CheckBox Hide selection on losing focus

Determines whether the visual indication of the selected text remains when the editor loses focus.

Memo editor options

CheckBox Inserting Return characters

Specifies whether a user can insert return characters into text.

CheckBox Inserting Tab characters

Specifies whether a user can insert tab characters into text.

CheckBox Word wrap in grid

Determines whether long strings are wrapped in grid.

CheckBox Popup memo editors

Turns on popup memo editors for text BLOB type columns.

Environment Options - Grid - Column Options

Spin editor options

CheckBox Use Ctrl+Up instead of Up to increase value

Allows you to use Ctrl+Up and Ctrl+Down key combinations for editing spinner values (for INTEGER column values).

CheckBox Show large increment buttons

Determines whether fast buttons (for large increment) are visible within the editor.

Increment

Specifies the increment value for the spin editor (spinner control).

Large increment

Specifies the large increment value for the spin editor (spinner control).

Spin editor buttons' position

Specifies the position of spin editor (spinner control) buttons: vertical, horizontal / left and right or horizontal / right.


Backup Database

You can create database backups with the help of the Backup Database Wizard.

You can open the wizard using one of the following commands:

  1. Choose Services | [image] Backup Database in the main program menu.
  2. Choose Tasks | Backup Database in the database context menu.


Restore Database from Backup

Restoring of a database is a process of copying data from a database backup.

This wizard will help you to restore the database from a backup and prepare it for the work.

To open the wizard, you can use one of the following commands:

  1. Choose Services | [image] Restore Database in the main program menu.
  2. Choose Tasks | Restore Database in the database context menu.


Reindex

Object Reindex Wizard allows you to rebuild corrupted indexes (with PostgreSQL routines used).

You can open the wizard using one of the following commands:

  1. Choose Services | [image] Reindex in the main program menu.
  2. Choose Tasks | [image] Reindex Database in the database context menu.


Database Statistics

The Database Statistics service is intended for browsing and reporting information about database activity. Provides counting of accesses to tables and indexes.

You can open the wizard using one of the following commands:

  1. Choose Services | [image] Database Statistics in the main program menu.
  2. Choose Tasks | [image] Database Statistics in the database context menu.


Localization

The Localization section of the Environment Options dialog is provided for managing the localization files of SQL Manager for PostgreSQL.

You can create your own *.lng files similar to those available in the %program_directory%\Languages folder, add them to the list of available languages and set the new language as the program interface language.

Default directory

Use the Explorer ExplorerButton button to specify the directory where the *.lng files are to be stored by default.

Choose program language

Use the drop-down list of available languages to select the interface language to be applied to the application.

CheckBox Auto scan languages on startup

When checked, the directory with localization files will be scanned automatically at the application startup; all the languages found will be added to the list of available languages.

Available Languages

Lists all the languages available for localization and the corresponding *.lng files. Double-click a language in the list to edit its name or the *.lng file.

Add Defaults

This button is used to search for *.lng files in the Default directory and add all of them to the Available Languages list.

Add

Opens the Add language dialog where you can specify your own localization file and set the language name.

Edit

Opens the Edit language dialog where you can change the language name or select another localization file for the specified language.

Delete

Removes the selected language from the Available languages list (without confirmation).

Environment Options - Localization

See also:

Localization


Global Shortcuts

This section allows you to view/edit shortcuts most needed actions when working with SQL Manager for PostgreSQL.

Environment Options - Global Shortcuts

To edit shortcut, select the required action click the ellipsis button and press the preferred key combination to assign it with the action.

Environment Options - Global Shortcuts - Edit


Find Option

The Find Option section allows you to search for options available within the Environment Options dialog easily and quickly.

Option

In this field you can enter the name of the option to search for within SQL Manager Environment Options.

Environment Options - Find Option

The Available options area lists all options of the Environment Options category according to the specified name. The Option Kind, Category and Group columns specify option type and location.

Select the required option in the list and click iconFindText Show Option to open the corresponding section where you can view/edit the value of this option. For your convenience the required option is marked with an animated iconFindOption icon.


Editor Options

Editor Options allow you to set the parameters of viewing and editing SQL statements within Query Data and other SQL editing tools of the SQL Manager application.

To open the Editor Options window, select the Options | Editor Options... main menu item, or use the Editor Options btnEditorOptions button on the main toolbar.

General

Display

SQL Formatter

Key Mapping

Spell Checking

Find Option

See also:

Environment Options

Save Settings


General

Editor options

CheckBox Auto indent

If this option is checked, each new indention is the same as the previous one when editing SQL text.

Indents and outdents are used in the process of text editing to make the source code easier to read.

CheckBox Insert mode

If this option is checked, the insert symbols mode is on by default.

CheckBox Find text from cursor

If this option is checked, the From Cursor mode will be set in the Find Text and Replace Text dialog.

CheckBox Always show hyperlinks

If this option is checked, hyperlinks are displayed in the editor window. To open a link, click it with the Ctrl key pressed.

CheckBox Double click line

If this option is checked, double-clicking the line on which the cursor is set selects the whole line.

CheckBox Trim trailing spaces

If this option is checked, all spaces after the last symbol in line will be trimmed.

CheckBox Fixed line height

Prevents line height calculation. If this option is checked, the default line height is taken.

CheckBox Persistent blocks

Keeps marked blocks selected even when the cursor is moved with the arrow keys used, unless a new block is selected.

CheckBox Fixed column move

If this option is checked, the caret keeps its horizontal position when moved between lines.

CheckBox Optimal fill

Check this option to enable optimal algorithm of filling text content in the working area of the editor.

CheckBox Unindent keep align

Keeps align for the lines that are not indented.

CheckBox Smart caret

This option determines the caret movement (up, down, line start, line end). The caret is moved to the nearest position on the screen.

CheckBox Resolve aliases

Enables/disables the syntax highlight and code completion features for aliases.

Editor Options - General

CheckBox Overwrite blocks

Replaces a marked block of text with whatever is typed next. If Persistent Blocks is also selected, the text you enter is appended to the currently selected block.

CheckBox Show caret in read only mode

Displays/hides the caret in read-only mode.

CheckBox Copy to clipboard as RTF

If this option is checked, the selected text is copied in RTF format.

CheckBox Drag and drop text

This option allows to drag and drop selected text.

CheckBox Group undo

This option allows you to undo multiple actions of the same kind.

CheckBox Group redo

This option allows you to redo multiple actions of the same kind.

CheckBox Cursor beyond EOL

If this option is checked, the horizontal position of a cursor is kept. If you move the cursor (using the Up and Down arrow keys) onto a line having length less than the current cursor horizontal position, it will be positioned after the last symbol of the line.

CheckBox Enable column selection

Enables/disables column selection mode.

CheckBox Hide cursor on type

Hides/displays mouse cursor within the working area while a user is typing some text.

CheckBox Hide dynamic (no focus)

Hides dynamic highlights when an editor is not focused.

CheckBox Collapse empty lines

Collapses empty lines after a text range when this range has been collapsed.

CheckBox Scroll last line

When the option is enabled, you can scroll to the last line of the text only, otherwise you can scroll to the end of the page.

CheckBox Seek variables

Disables code completion feature for variables.

CheckBox Word wrap

When on, text is wrapped at the right margin of the editor area to fit in the visible area.

CheckBox Variable horizontal scrollbar

If this option is checked, the horizontal scrollbar varies according to the current content of the editor.

CheckBox Float markers

When enabled, markers are linked to the text, and they will move with the text while the text is being edited; otherwise the markers are linked to the caret position, and stay unchanged while the text is being edited.

CheckBox Undo after save

Keeps undo buffer unchanged after saving.

CheckBox Disable selection

Disables any selection when editing.

CheckBox Draw current line focus

Draws the focus rectangle around the current line when the editor has focus.

CheckBox Hide selection (no focus)

Hides the selection when the editor loses focus.

CheckBox Greedy selection

Selects an extra column/line in column/line selection modes.

CheckBox Keep selection mode

Enables selection for caret movement commands (like in BRIEF).

CheckBox Select search result

Determines whether the search result should be selected.

CheckBox Smart paste

When this option is enabled, the editor gets both Unicode and ANSI content from the clipboard, converts them using the selected character set and selects the best text to be pasted. This allows getting correct text copied from both ANSI and Unicode applications disregarding the currently selected keyboard language.

CheckBox Disable all code features

This option disables code completion, code folding, highlight and all options that are set on the Quick Code page. For options that are set on the Highlight page, the defaults will be applied.

Collapse level

Specifies the level of text ranges that will be affected by the "Collapse all" command.

Undo limit

Defines the maximum number of changes possible to be undone.

Tab mode

Specifies the way the TAB key is processed. Possible values are: Use tab character (inserts a tab character); Insert spaces (inserts space characters); Dialog behaviour (when the edit control is in a dialog, the focus is switched to the next control); Smart tab (tabs to the first non-white space character in the preceding line).

Tab stops

Defines the tab length used when editing a text.

Comment symbols

Defines the symbols which will be used to comment code fragments.

Block indent

Specify the number of spaces to indent a marked block.

Hint: The Reset to Defaults button which is common for all sections of the Editor Options dialog opens a menu with items allowing you to discard all changes and reset options of the current category or of all categories to their defaults.


Display

SQL Manager for PostgreSQL
  • Index
  • « Prev
  • Next »

Default editor fonts

Use these options to set the font and size used in the editor.

CheckBox Show only fixed-width fonts

Use this option to display only fonts with fixed width in the Font dialog.

Gutter

CheckBox Show line numbers

If this option is checked, line numbers are displayed in the SQL text editor window.

CheckBox Gutter auto width

Enable this option to specify that the gutter width will be adjusted automatically.

CheckBox Display line state

If this option is checked, a colored line indicating the state of all altered lines in the text is displayed at the gutter of the editor window.

CheckBox Use code folding

Check this option to enable to code folding feature of Query data.

Width

Defines the gutter width in the editor window.

Use these options to set the Font, Size and Numbering style used in the gutter.

CheckBox Show only fixed-width fonts

Use this option to display only fonts with fixed width in the Font dialog.

Editor Options - Display

Right margin

CheckBox Visible

Makes the right text margin visible.

CheckBox Word break

Allows breaking the words at the right margin.

Position

Defines the position of the right text margin in the editor window.

Color

Defines the color of the right margin in the editor window. Select an item from the drop-down list or click the ellipsis EllipsisButton button to select a color using the Color dialog where you can specify the required color from the palette.

Code staples

CheckBox Visible

Makes the code staples visible in the editor window.

CheckBox Single color

Check the option to apply a single color for code staples.

CheckBox Offset

Specify the offset value for code staples.

Color

Defines the code staples color in the editor window (if the Single color option is deselected). Select an item from the drop-down list or click the ellipsis EllipsisButton button to select a color using the Color dialog where you can specify the required color from the palette.

Fonts

Use these options to set the fonts, style, size and color used in the editor. If the Show only fixed-width fonts option is checked, only fonts with fixed width are displayed in the Font dialog.


Color Scheme

Scheme

Select the default color scheme for all editors: Default (Light) or Dark.

Editor Options - Display - Highlight

The Element list contains all elements available in SQL editors of the program. For your convenience the preview area (located below the Element list) illustrates the changes being made to each of the elements

Controls for changing the properties of the item selected in the Element list are located on the right. Use the following instructions for each of the elements.

CheckBox Bold

Highlights the element with bold.

CheckBox Italic

Makes the element text cursive.

CheckBox Foreground

Select the foreground color for the element.

CheckBox Background

Select the background color for the element.

CheckBox Effects

Enables additional effects for the element text.

See also:

Code Completion


Code Completion

The Code Completion section of the Editor Options dialog allows you to specify the automatic features, fonts, styles, foreground and background colors, borders and other attributes of the text used by the editor to display objects for 'quick code': tables, UDFs, indices, columns, foreign keys, procedures, functions, views, triggers, scheduled events, SQL keywords, SQL functions.

Automatic features

CheckBox Code completion

If this option is checked, then on typing the first word characters in the SQL text editor you will be offered some variants for the word completion in a popup list (an analogue of the Code Insight feature in Delphi IDE). The popup list will appear after a period of time defined by the Delay option.

Delay

Using this option you can change the time after which completion variants popup.

Sensitivity

This option allows you to set the number of characters to be typed before code completion is activated.

CheckBox Parameters completion

If this option is checked, the Delphi-like hint for key words is enabled.

CheckBox Group by type

If enabled, the items in the code completion list are sorted by type, otherwise they are sorted by name.

CheckBox Sort column names

Enable this option to force sorting for column names.

CheckBox Show information hints

This option enables/disables information hints for variants offered by code completion feature.

CheckBox Auto launch keyboard templates

Allows you to use keyboard templates for faster typing frequently used expressions (see Keyboard Templates).

CheckBox Accept by Space key too

Enables selecting the completion item with Space key.

Editor Options - Display - Quick Code

Completion list object

The list contains all objects for which you can set quick code parameters. For your convenience the preview area (located to the right of the Completion list object list) illustrates the changes being made to each of the objects.

If you press the Disable element button, the standard settings will be applied to this object; the button text will change to Enable element. If you press this button, you will be able to change font and color attributes for this object.

Controls for changing the properties of the item selected in the Completion list object list are located on the right.

See also:

Highlight


SQL Formatter

SQL Formatter is a feature implemented in SQL Manager for PostgreSQL and is a useful tool for formatting SQL queries and scripts, making SQL statements easy to read. SQL Formatter is introduced in Query Data, Execute Script and some object editors.

The Settings tab of the SQL Formatter section allows you to enable this feature and apply SQL formatting to subqueries, if necessary.

CheckBox Format SQL query

Check this option to enable SQL formatting.

CheckBox Format subquery

Enables SQL formatting for subqueries.

Editor Options - SQL Formatter

See also:

Query Data


SQL Words

The SQL words page of the SQL Formatter section allows you to select the key words for each action of SQL formatter and to set formatting parameters.

Wrap first element

Wraps the selected text at a specific column. Select the SQL key words after which formatting should be applied.

Params in line/list

Allows you to display the parameters followed by the defined key words in list or in line.

Editor Options - SQL Formatter - SQL Words

OR - AND

Set the placement of the AND an OR operators according to the operands followed by them. See the example below.

RadioButton Left

WHERE

AND ...

AND ...

AND ...

RadioButton Separate

WHERE

...

AND

...

AND

RadioButton Right

WHERE

... AND

... AND

... AND

The Keywords case / Identifiers case options allow you to define the case of the corresponding items.

You can choose UPPER, lower, Capitalize.

Default case means that the name of the identifier/keyword remains "AS IS".

CheckBox Space before bracket

Adds a "space" character before the opening bracket and after the closing one.

CheckBox Space into brackets

Adds a "space" character after the opening bracket and before the closing one.

Indent in list

Sets the size of indent relatively to the previous string.


Managing Changes

Change management system allows you to:

  • Systematization of release database new versions process: storing different database versions; tracking of database changes; Getting (storing, testing) change scripts which reveal differences between two database states.
  • Possibility to rollback database to definite state.
  • Control of database changes.

When a user of the system makes typical actions, such as getting previous version of a document or creating new version etc., he works with a local copy of repository. As the amount of applied changes grows, repositories of various developers become more different. This results in necessity of synchronization of repositories. Synchronization can be performed by interchange of patches or change sets among developers.

Enabling Change Management

Disabling Change Management

Creating Label/Branch/Tag

Checking Repository

Adding Changes to Repository

Releasing New Version of Database

Browsing History of Changes


Creating Label/Branch/Tag

SQL Manager for PostgreSQL
  • Index

Create Label/Branch/Tag

Tag, label and branch can be created with Create Tag Wizards.

Branch is an independent direction of database development. It is a copy of a repository part (single directory as a rule), which can be modified with no effect on other branches. Objects in different branches are identical before branching point and divergent after it.

Label is a branch where no changes are to be made. Physically it's a copy of marked files and directories state.

Tag is a special mark that indicates certain product release version. It is a marks for all files of the database repository within the certain version.

The wizard can be launched in the following ways:

  1. Select the Change Management | Create Branch/Label/Tag item of the host or database context menu and define parameters of the created object in the appeared wizard.
  2. Select the Tools | Change Management | Create Branch/Label/Tag item of the main menu and define parameters of the created object in the appeared wizard.


Checking Repository

Check Version Control Repository Wizard reveals differences (if any) between current database state and its description in the VCS repository and allows you to make repository correction.

You can check version control repository in the following ways:

  1. Select the Change Management | Check Repository item of the host or database context menu and define necessary settings in the opened wizard.
  2. Select the Tools | Change Management | Check Repository item of the main menu and define necessary settings in the opened wizard.


Adding Changes to Repository

Get Change Script Wizard is used for generation of scripts allowing to change database state. Any database state from VCS can be set as source and target one.

To launch the wizard select the Change Management | Get change script item of the host or database context menu.

Alternatively you can select the Tools | Change Management | Get change script item of the main menu.


Releasing New Version of Database

This wizard allows you to create a script that transforms previous version of database to new one.

The wizard will perform the following operations:

  1. Check whether database corresponds with repository.
  2. Create label/tag for new version of database.
  3. Get script allowing to bring database to new version.
  4. Test change script on test database.

To launch the wizard:

  1. Select the Change Management | Release New Version of Database item of the host or database context menu.
  2. Select the Tools | Change Management | Release New Version of Database item of the main menu.


Browsing History of Changes

To browse history of changes in database:

  • Select the Tools | Change Management | iconChange Management - History History main menu item.
  • Select the Change Management | iconChange Management - History History item of the host or database context menu.

To browse history of object changes select the Change Management | iconChange Management - History History item of the object context menu.


View Server Configuration

There are many configuration parameters that affect the behavior of the database system which can be set up via Server Configuration manager.

You can View Server Configuration in one of the following ways:

  1. Choose Services | Server configuration in the program main menu and set the server configuration parameters in the opened Server Configuration.
  2. Choose Server configuration in the host context menu and set the server configuration parameters in the opened Server Configuration.


Unregister Host

btnUnregisterHost You can unregister a host in one of the following ways:

  1. Choose Database | Unregister Host in the main program menu - > confirm the removal of a host in the pop-up window.
  2. Choose Unregister Host in the host context menu - > confirm the removal of a host in the pop-up window.
  3. Choose Unregister Host in the database context menu - > confirm the removal of a host in the pop-up window.


View Server Log SQL Parser

Server Log SQL Parser allows you to analyze PostgreSQL server session logs in a simple way providing the ability to sort, filter and group log statements.

You can View Server Configuration in one of the following ways:

To launch the tool, select the Services | Server Log SQL Parser main menu item.


View Server Status

The Server Status viewer allows you to get common information on current connections to the server, locks, prepared transactions, and to view server log files.

You can View Server Status in one of the following ways:

  1. Choose Services | Server Status in the program main menu.
  2. Choose Server Status in the host context menu in the DB Explorer tree.


Register Database

btnRegisterDB To start working in SQL Manager for PostgreSQL with the existed database, you should first register it in the program. Use the Register Database Wizard to do it.

You can register a database in one of the following ways:

  1. Choose Database | Register Database in the main program menu and define the necessary settings in the opened Register Database Wizard.
  2. Press the Register Database btnRegisterDB button on the SQL Manager for PostgreSQL toolbar and define the necessary settings in the opened Register Database Wizard.

Registering several databases at once

Choose Database | Register Database in the main program menu, disable the Register a single database

feature when setting host connection parameters and at the next step choose the databases located on the indicated server.


Connect to Database

btnConnectToDB You can connect to a database in one of the following ways:

  1. Choose an unconnected database in the BD Explorer and then choose Database | Connect to database in the main program menu.
  2. Choose an unconnected database in the BD Explorer and then choose Connect to database in the database context menu.
  3. Choose an unconnected database in the BD Explorer and then press Connect to database on the DB Explorer toolbar.
  4. Choose an unconnected database in the BD Explorer and then double-click the database alias.
  5. Choose an unconnected database in the BD Explorer and then use Ctrl+Shift+С to connect to the database.


Disconnect from Database

btnDisconnectFromDB You can disconnect from a database in one of the following ways:

  1. Choose a connected database in the BD Explorer and then choose Database | Disconnect from database in the main program menu.
  2. Choose a connected database in the BD Explorer and then choose Disconnect from database in the database context menu.
  3. Choose a connected database in the BD Explorer and then press Disconnect from database on the DB Explorer toolbar.
  4. Choose a connected database in the BD Explorer and then use Ctrl+Shift+D to disconnect from the database.


Enable Login Prompt for Database

To enable the Login Prompt for databases, open the Database Registration Info dialog. Then go to the Options tab and check the CheckBox Login prompt before connection option.


Enable System Objects Display

To display system objects in DB Explorer tree, open the Database Registration Info dialog. Then go to the Options tab and check the CheckBox Show system objects option.


Change Database Default Charset

To change the default charset of a database, open the Database Registration Info dialog. Then go to the Connection tab and choose the necessary charset from the Font charset drop-down list.


Change Database Sort Order in DB Explorer

You can change the sort order of databases in the DB Explorer in the following ways:

  1. Drag the database name to the necessary position.
  2. Choose Sort by aliases in the database context menu. In this case the databases will be sorted alphabetically.


Design Database Visually

btnVDBD Visual Database Designer

You can open the Visual Database Designer in the following ways:

  1. Choose Tools | btnVDBD Visual Database Designer in the main program menu.
  2. Press the btnVDBD Visual Database Designer button on the main toolbar.
  3. Choose Tasks | btnVDBD Visual Database Designer in the database context menu.


Add Objects to Diagram

The main working area of the Visual Database Designer is the diagram area. You can work with the scheme of objects placed on the diagram.

You can add objects to a diagram in the following ways:

  1. Press the Reverse engineering btnReverseEngineer button on one of the toolbars and in the opened window choose schemes whose objects should be displayed in the diagram.
  2. Drag the object from the DB Explorer to the diagram area.
  3. Create an object using the corresponding command of the diagram or object context menu.


Extract Database Objects Structure and Data into SQL Script

btnExtractDB You can extract DB objects structure and data into SQL script using the Extract Database Wizard. The result script can be used to cop and restore your database.

You can open the DB Extract Wizard using the following commands:

  1. Choose Tools | btnExtractDB Extract Database in the main program menu.
  2. Press the Visual Extract Database btnExtractDB button on the main toolbar.
  3. Choose Tasks | btnExtractDB Extract Database in the database context menu.


Import Data

You can import data from external sources into a table or view in one of the following ways:

  1. Open the Data tab, press the Import Data button on one of the Data View toolbar and set import parameters in the opened Data Import Wizard.
  2. Open the Data tab, choose Data Manipulation | Import Data in the Data Grid context menu and set import parameters in the opened Data Import Wizard.
  3. Open the table context menu in the DB Explorer, choose the Import Data item and set import parameters in the opened Data Import Wizard.
  4. Open the Data tab and use the shortcut Ctrl+I.


Export Data as SQL Script

You can export data from a database table into SQL script with INSERT INTO statements in one of the following ways:

  1. Open the Data or Results tab, press the Export Data as SQL Script on one of the Data View toolbars and set export parameters in the opened Export as SQL Script wizard.
  2. Open the Data or Results tab, choose Data Manipulation | Export Data as SQL Script in the Data Grid context menu and set export parameters in the opened Export as SQL Script wizard.
  3. Open the table context menu in the DB Explorer, choose the Export Data as SQL Script item and set export parameters in the opened Export as SQL Script wizard.

Note: In order to extract table DDL (CREATE TABLE statement), check the Add CREATE TABLE statement box at Step 1.


Cancel Data Changes

You can cancel data changes by pressing the HowTo - Grid View - Cancel Edit Cancel Edit button in the Data Management section of the navigation bar.

Note: If the transaction confirmation is enabled, then in order to Cancel Edit, press Rollback transaction.


Create HTML Report of Database Objects Metadata

To create HTML Report select the Tools | [image] HTML Report item from the main menu and define necessary report settings using HTML Report Wizard.


View Objects Metadata

Print Metadata tool allows you to generate and print metadata reports of any database object(s).

To export metadata to printable format:

  1. Select the Tools | btnPrintMetadata Print Metadata item of the main menu, then mark the needed objects and define printing options in the appeared window. After that click the btnPrintPreview Preview item on the navigation bar or tool bar.
  2. Select the Tools | btnPrintMetadata Print Metadata item, then mark the needed objects and define printing options in the appeared window. After that press the btnPrintPreview Preview item on the navigation bar or toolbar.


Key Mapping

For your convenience key mapping is provided in SQL Manager for PostgreSQL. On this page you can set the shortcuts for various commands/operations according to your needs.

Use the Commands list on the right to select the command for which you need to make a shortcut, then place cursor into the Key editor and press the key combination you find useful (use Ctrl Alt Shift buttons). After setting the shortcut, press the New button to add it to the list of existing Key combinations. If the specified shortcut is already assigned to another command/operation, an error message with the command/operation will be returned.

Editor Options - Key Mapping

Note: It is possible to set more than one key combination for the same command/operation (e.g. Ctrl+K, Ctrl+H) using the Add button.

If necessary, you can export the current Key mapping list to an external file by pressing the Export button.

Manage the shortcuts within the Key combinations list using the Delete (to remove the selected item) and the Clear (to remove all shortcuts for this command/operation) buttons.

It is also possible to save a custom key mapping scheme, if necessary:

  • set the shortcuts for the appropriate commands/operations;
  • click the Save As... button;
  • input the new scheme name in the corresponding dialog.

To delete a scheme, select it in the Scheme name drop-down list and press the Delete button.

See also:

Query Data

SQL Manager shortcuts


Spell Checking

Spell checking is a new feature implemented in SQL Manager for PostgreSQL for your convenience.

Set the necessary Spell checker mode:

RadioButton Highlighting

In this mode incorrectly spelled and misprinted words are highlighted in the editor.

RadioButton Autocorrection

In this mode incorrectly spelled and misprinted words are replaced with the corresponding words from the Substitutions list automatically.

RadioButton None

In this mode the spelling checker is disabled.

Use the Add... button to add a new item to the Substitutions list, the Edit... button to alter the selected substitution, and the Delete button to remove the selected substitution from the spelling checker vocabulary.

Editor Options - Spell Checking

Case sensitivity

CheckBox Support case consistency with substitution

If this option is selected, the spelling checker uses the case of words-substitutions when performing a replacement.

CheckBox Ignore case while spell checking

Check this option to disable case checking.

CheckBox Keep the misprint case when replacing

Check this option if you do not wish to change the case of the replaced word.

Misprints

Controls of this group allow you to manage the spelling checker vocabulary: use the Add... button to add a new misprint to the vocabulary, the Auto button to use the default list of misprints, the Edit... button to change the selected misprint, the Delete button to remove the selected misprint from the vocabulary, and the Clear button to empty the list of misprints for the currently selected substitution.

It is also possible to exclude a misprint from spell checking without deleting the misprint. This misprint will therefore remain in the vocabulary, but it will be ignored by the spelling checker.

To mark a misprint as excluded, you need to move it from the Check list to the Ignore list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the misprints from one list to another.


Find Option

The Find Option section allows you to search for options available within the Editor Options dialog easily and quickly.

Option

In this field you can enter the name of the option to search for within SQL Manager Editor Options.

Editor Options - Find Option

The Available options area lists all options of the Editor Options category according to the specified name. The Option Kind, Category and Group columns specify option type and location.

Select the required option in the list and click iconFindText Show Option to open the corresponding section where you can view/edit the value of this option. For your convenience the required option is marked with an animated iconFindOption icon.


Save Settings

Save Settings Wizard allows you to export the settings of SQL Manager for PostgreSQL - wholly or partially - to a single *.reg file which can be applied afterwards to SQL Manager for PostgreSQL installed on another machine, or it can be used to backup previous settings.

To start the wizard, select the Options | Save Settings main menu item.

  • Specifying destination file
  • Selecting settings
  • Selecting databases
  • Saving settings

To apply saved settings you need to open the created *.reg file, then press the OK button in the window appeared. All settings will be applied automatically (they will be added in the Windows Registry).


Specifying destination file

This step of the wizard allows you to specify the location of the destination file.

Filename

Use the btnSaveAs button to set the path to the *.reg file where the application settings are to be saved.

Note: If the target file already exists, the application will show a warning dialog where you can choose the action you need.

Save Settings - Specifying destination file

Press the Next button to proceed to the next step of the wizard.


Selecting settings

This step of the wizard allows you to specify the information you need to be saved to the result file: Database registration info, Database projects, Tabs, Environment options, Editor options, Visual options, Keyboard templates, External tools list, Form placements, MRU lists.

Save Settings - Selecting settings

Press the Next button to proceed to the next step of the wizard.


Selecting databases

This step of the wizard allows you to select the database(s) to save the registration settings.

To select a database, you need to move its alias from the Available Databases list to the Selected Databases list. Use the Move all to Selected Move to Selected Move to Available Move all to Available buttons or drag-and-drop operations to move the databases from one list to another.

Save Settings - Selecting databases

Press the Next button to proceed to the next step of the wizard.


Saving settings

After the saving settings operation has been configured, you can immediately start the process.

If all the settings are saved correctly, you will get the following message:

Save Settings - Saving settings - Completed

Click the Run button to run the restore database operation.

If necessary, you can click Details to display/hide extended information about the operation.


Localization

When using SQL Manager for PostgreSQL, your are provided with multi-language interface support. You can change the program language, specify the directories for your localization files easily, edit existing localizations and create your own localization files.

Changing Program Language

  • select the Options | Select Program Language... main menu item;
  • select the interface language in the Select Language dialog;
  • click OK to apply the language and close the dialog.

Editing Program Localization

  • open one of the program windows (e.g. Table Editor, Query Data) where you wish to edit the localization of captions and hints;
  • use the Shift+Ctrl+L keyboard shortcut to open the Localization Editor window;
  • edit window captions and hints as necessary;
  • click the btnSave Save button on the toolbar.

Note: The Localization Editor window is only available if the currently selected language is different from the default.

Creating New Localization Files

  • create a new localization file similar to those located in the %program_directory%\Languages folder;
  • select the Options | Environment Options main menu item;
  • proceed to the Localization section of the Environment Options dialog;
  • click the Add button;
  • set the language name and the path to the new *.lng file within the Language Info Editor dialog.

The new language is added to the list of available languages. Now you can set it as the interface language using the Select Program Language dialog or the Localization section of the Environment Options dialog.

See also:

Localization

Language Info Editor


Localization Editor

The Localization Editor window allows you to edit the captions and hints of any SQL Manager window, if the selected program language is different from the default one.

To call this window, use the Shift+Ctrl+L shortcut in any child window of SQL Manager for PostgreSQL.

The working area of the window contains the element names and the corresponding strings divided by the "=" character. These strings are what you see in the program as menu items, window captions, button hints, etc. Edit them to change the program appearance. Be careful and do not edit the identifiers that stand before the "=" character - this will not produce any effect.

For your convenience the Find and Replace features are provided - the corresponding btnFindText and btnReplaceText toolbar buttons are used to call the Find Text dialog or the Replace Text dialog respectively. The Search Again btnSearchAgain button enables the repeated search for the text that was last searched.

Localization - Localization Editor

When you are done with editing, click the btnSave Save button on the toolbar to apply the changes you have made.


Select Program Language

The Select Language dialog allows you to select a language for SQL Manager for PostgreSQL localization.

To open this dialog, select the Options | iconSelectLanguage Select Program Language... main menu item.

The dialog displays the list of available languages configured on the Environment Options | Localization page. Select a language from the list and click OK to confirm your choice and close the dialog.

Localization - Select Program Language


Keyboard Templates

The Keyboard Templates window allows you to create new keyboard templates for quicker typing regularly used expressions and to edit the existing ones.

To open this window, select the Options | iconKeyboardTemplate Keyboard Templates... main menu item.

To add a new keyboard template, click the Add Template... button, set the template name and define the template expression. In the upper right area of the window you can change the case of the template expression (As is, Uppercase, Lowercase, First upper).

You can deactivate an existing template by selecting it from the list on the left and removing the Active flag of the template.

If necessary, you can also edit the template name using the Edit Template... button, delete the template using the Delete Template button or edit the template expression within the Expansion area of the window. For faster editing you can use the Cursor, Author, Time, Date, Clipboard, Marker buttons.

Hint: Add/edit/delete template items are also available in the context menu of the template list on the right.

CheckBox Old style

This option specifies whether the selected keyboard template expansion should conform to the template specifications used in the earlier versions of SQL Manager for PostgreSQL.

Once you have defined the templates, you can use them in Query Data. First of all, make sure that the CheckBox Auto launch keyboard templates option is selected on the Quick Code page of the Editor Options dialog. When editing SQL text in Query Data, type a template name and use the Ctrl+J shortcut: the text associated with the template (Expansion) will be inserted automatically.

Hint: The Reset to defaults button which is available at the bottom of the Keyboard Templates dialog allows you to discard all changes and restore the settings to their defaults.

See also:

Code Completion

SQL Manager shortcuts


Object Templates

The Object Templates window allows you to preset the definition template for the name and/or body of an object to be created.

To open this window, select the Options | iconObjectTemplates Object Templates... main menu item.

Select an object in the tree (View, Function: SQL, C, PL/pgSQL, PL/Tcl, PL/Perl, PL/Python) and set its template using the editor area.


Find Option dialog

The Find Option dialog allows you to search for SQL Manager options easily.

To open this dialog, select the Options | iconFindOption Find Option main menu item.

Option

In this field you can enter the name of the option to search for within the entire set of SQL Manager options.

Find Option dialog

The Available options area lists all options by categories according to the specified name. The Option Kind, Category and Group columns specify option type and location.

Select the required option in the list and click iconFindText Show Option to open the corresponding dialog where you can view/edit the value of this option. For your convenience the required option is marked with an animated iconFindOption icon.


Program interface

Main menu

The main menu allows you to perform various Database operations, open To-Do List and activate/deactivate Database Explorer, SQL Assistant and various toolbars within the View menu, manage your databases using items of the Tools and Services menus, customize the application using the Options menu, manage SQL Manager Windows using Window List and other tools and access Registration information and product documentation, update the product to the latest version using the corresponding items available within the Help menu.

Appendix - Program interface - MainMenu

Note: To learn how to configure SQL Manager menus, refer to the Customize toolbars and menus page.

Navigation bars in object editors and program tools

Navigation bars are interface elements that enable users to quickly locate tools they need. Navigation bar items are displayed within a group with the help of links. A typical Navigation bar of SQL Manager contains links to commonly accessed tools (refresh, print, restore default size of the window), options pertaining to the editor or tool, and specific tools.

Appendix - Program interface - NavBar - Expanded

Navigation bar panes (groups) can be expanded/collapsed. When expanded, a pane provides access to its links; when collapsed, panes are displayed as headers only.

To expand/collapse a pane, click the pane header. The [image] [image] icons indicate the current pane state (collapsed/expanded respectively).

Appendix - Program interface - NavBar - Collapsed

Note: Depending on the current tab selection, Navigation bars in most of the program tools expand to one or more additional panes with tab-specific actions that can be useful for working with the object or service.

Hint: Most items of the Navigation bars are also available on the Toolbars.

Toolbars in the main program window, object editors and program tools

A toolbar is a horizontal row or vertical column of selectable image buttons that give the user a constantly visible reminder of and an easy way to select certain application functions. Most SQL Manager editors and tools are supplemented with toolbars.

Appendix - Program interface - Toolbar

To enable the toolbars in SQL Manager for PostgreSQL, open the Environment Options dialog, proceed to the Windows section there and select RadioButton Toolbar (if you need the toolbar only) or RadioButton Both (if you need both the toolbar and the Navigation bar) in the Bar style for child forms group.

Hint: Most SQL Manager toolbars are dockable, i.e. you can place a toolbar to any available location within the parent window.

To learn how to configure toolbar items, refer to the Customize toolbars and menus page.

Progress bars

A progress bar is an interface element that conveys the progress of a task or service. Several SQL Manager editors (e.g. Execute Script),tools (e.g. Dependency Tree) and wizards (e.g. Import Data Wizard) are supplemented with progress bars indicating the progress of lengthy operations.

The graphic of SQL Manager progress bars is accompanied by a textual representation of the progress in the percent format.

Splitters

Splitter controls are used to resize docked controls at run time. In SQL Manager for PostgreSQL the splitter controls are used on the main form, DB Explorer, and in program tools and editors as a separator between the working area and Navigation bars, status bars, etc.

Incremental Search bar

Incremental search bar is the tool which is available in the status bar area of some SQL Manager tools. The bar is normally called through the Ctrl+I shortcut. Type in the first letters of the search string, and the corresponding string will be highlighted in the search scope.


Viewing object DDL structure

The DDL (Data Definition Language) tab displays the SQL statement for creating the object with all its subobjects, if any. This text is read-only. If you want to change the object definition, use the appropriate editor tabs instead, or copy the text to the Windows Clipboard to paste it in the Query Data or Execute Script Editor.

Appendix - Viewing DDL structure

Hint: If more convenient, you can use the Save DDL to file and Open DDL in Query Data items available on the DDL pane within the Navigation bar of object editors.


Editing object description

The Description tab allows you to view and edit the comment for the object (optional).

Appendix - Editing object description

You can save changes made in this area by clicking the Save Description item on the Navigation bar.

If the changes have not been saved, on attempt to select another tab of the editor you will be prompted for an action whether changes in the object description should be saved or discarded.


Browsing object dependencies

The Dependencies tab allows you to view objects that depend on the object being edited, and the objects that the edited object depends on.

While the tree of dependencies is built, the progress bar is displayed in the status area of the editor window.

Appendix - Browsing object dependencies

Hint: To open a dependent object or a depending object in its editor, you can simply double-click the object alias in the Objects that <object_name> depends on and Objects that depend on <object_name> lists.

See also:

Dependency Tree


Setting object permissions

The Permissions tab allows you to view the permissions currently allocated for this object, and to grant permissions on the object to any of the existing principals.

Appendix - Setting object permissions

For details see Grant Manager.


Changing Metadata window

The Changing Metadata window is used to trace the errors and edit SQL statements during their compilation. The compilation window appears each time metadata is changed, both when the compilation is successful and when there are compilation errors. To hide this window for successful metadata changes, select the CheckBox Don't show this window on success option.

Note: This option is unavailable for changing metadata of database with Change Management enabled.

If Change Management is enabled for database whose metadata is being changed, the following features become available:

Comment for Change Management

Use this field to comment transaction to ease finding it when browsing history.

Log to VC

Use the drop-down list to define whether to add this transaction to version control log always, only if script changes objects or to log only statements that change objects.

Compile SQL

This area displays the SQL statement pending to be executed to perform metadata changing. In this area you can view and edit the SQL statement.

In case of a compilation error the Error tab also becomes visible - here you can view the error description returned by the server.

Commit

This button starts execution of the statement(s). Click it to commit the current transaction. This button is available only if there were no errors in compilation.

Rollback

This button cancels the script execution and allows you to return to the previous stage (editor window or DB Explorer).

Rollback and Recompile

This button calls for recompilation with the changes you made in the Compile SQL area. Use this button after correcting the SQL statement.

Appendix - Changing Metadata window

If script execution was stopped due to timeout limit exceeding, you can recompile it with double or unlimited timeout using corresponding buttons.

If necessary, you can copy information to clipboard and save it in a text editor afterwards (the button is only enabled when a compilation error occurs).

If you want this window to appear only in case of an error, uncheck the CheckBox Confirm metadata changing (Changing Metadata Window) option (checked by default) available within the Confirmations section of the Environment Options dialog.


Find Text dialog

The Find Text dialog is provided for quick and flexible searching for specified text within the working area of SQL Manager editors.

Text to find
Enter a search string in this box. The Arrow-Down button which can be found next to the input box allows you to select any of the previously entered search strings.

Options

CheckBox Case sensitive
This option can be used to differentiate uppercase characters from lowercase ones during the search process.

CheckBox Whole words only
Use this option to search for words only (with this option off, the search string might be found within longer words.)

CheckBox Regular expressions
Recognizes regular expressions in the Text to find field.

For example, you can type "empl*" to search for metadata containing the "empl" substring; enter "^emp" to search for words starting with "emp" or "^emp|emp$" to search for the string "emp" at the beginning or at the end of the string.

Note: The syntax of regular expressions that can be used in the Text to find field is similar to that used in Perl regular expressions. Comprehensive information about it can be found at http://perldoc.perl.org/perlre.html#Regular-Expressions.

Direction

RadioButton Forward

Searches from the current position to the end of the working area.

RadioButton Backward

Searches from the current position to the beginning of the working area.

Scope

RadioButton Global

Searches within the entire working area, in the direction specified by the Direction setting.

RadioButton Selected text

Searches only within the currently selected text, in the direction specified by the Direction setting. You can use the mouse or block commands to select a block of text.

Origin

RadioButton From cursor

The search starts at the cursor's current position, and then proceeds either forward to the end of the scope, or backward to the beginning of the scope depending on the Direction setting.

RadioButton Entire scope

The search covers either the entire block of selected text or the entire script (no matter where the cursor is in the Editor area) depending upon the Scope options.

CheckBox Mark search result with stack marker

The option toggles marking search results. If this option is selected, stack markers are set at all search positions - this makes it possible to jump from one marker (search result) to another within the text.

Click the Show All button to highlight every occurrence of the search string.


Replace Text dialog

The Replace Text dialog is provided for searching and replacing text within the working area of SQL Manager editors.

Text to find
Enter a search string in this box. The Arrow-Down button which can be found next to the input box allows you to select any of the previously entered search strings.

Text to replace
This box allows you to enter a string to replace the search string. The Arrow-Down button which can be found next to the input box allows you to select any of the previously entered strings. To replace the search string with an empty string, leave this input box blank.

Options

CheckBox Case sensitive
This option can be used to differentiate uppercase characters from lowercase ones during the search process.

CheckBox Whole words only
Use this option to search for words only (with this option off, the search string might be found within longer words.)

CheckBox Regular expressions
Recognizes regular expressions in the Text to find field.

CheckBox Replace with template
This option requires the Regular expressions option selection.

Enable this option to use regular expressions in the Text to replace field. Expression used in this field will be applied to each string that matches the Text to find expression.

Note: The syntax of regular expressions that can be used in the Text to find and the Text to replace fields is similar to that used in Perl regular expressions. Comprehensive information about it can be found at http://perldoc.perl.org/perlre.html#Regular-Expressions.

CheckBox Prompt on replace
Check this option if you wish to be prompted before replacing upon each occurrence of the search string. When this option is off, the search string is replaced automatically.

Direction

RadioButton Forward
Searches and replaces from the current position to the end of the working area.

RadioButton Backward
Searches and replaces from the current position to the beginning of the working area.

Scope

RadioButton Global
Searches and replaces within the entire working area, in the direction specified by the Direction setting.

RadioButton Selected text
Searches and replaces only within the currently selected text, in the direction specified by the Direction setting. You can use the mouse or block commands to select a block of text.

Origin

RadioButton From cursor
The search and replace process starts at the cursor's current position, and then proceeds either forward to the end of the scope, or backward to the beginning of the scope depending on the Direction setting.

RadioButton Entire scope
The search and replace process covers either the entire block of selected text or the entire script (no matter where the cursor is in the Editor area) depending upon the Scope options.

CheckBox Mark search result with stack marker
The option toggles marking search results. If this option is selected, stack markers are set at all search positions - this makes it possible to jump from one marker (search result) to another within the text.

Click the Replace All button to replace every occurrence of the search string. If you have checked the Prompt on replace option, the confirmation dialog box appears upon each occurrence of the search string.


Host Login dialog

This form appears when selecting a host without active database connections in the navigation bar. Services where this dialog can be called from are: User Manager, Group Manager, Server Status and Server Configuration.

This form contains all necessary options to define settings for connecting to host.

Provide authorization settings: User name and Password.

If tunneling required proceed to the respective tab to define tunneling parameters.

You can get sufficient information about tunneling here: SSH tunneling options, HTTP tunneling options.

Click the Test Connection button to check whether define settings are valid.

You can also get the connection information from database registration info. For this pick a database from the drop-down list in the bottom area of the window and click the Load connection info button.


Add parameter

The following dialog appears on adding or editing parameters.

Parameter name

Select the parameter from the dropdown list.

Value

View the current value and edit if necessary.

Parameter info

Here you can see the additional info about the parameter.

Description

Input the comments on the selected parameter.

Appendix - Add parameter

To obtain more information on specific parameters, refer to PostgreSQL documentation.


Format specifiers

The following format specifiers are supported in the format string:

Float/Integer format

0

Digit place holder. If the value being formatted has a digit in the position where the '0' appears in the format string, then that digit is copied to the output string. Otherwise, a '0' is stored in that position in the output string.

#

Digit placeholder. If the value being formatted has a digit in the position where the '#' appears in the format string, then that digit is copied to the output string. Otherwise, nothing is stored in that position in the output string.

.

Decimal point. The first '.' character in the format string determines the location of the decimal separator in the formatted value; any additional '.' characters are ignored.

,

Thousand separator. If the format string contains one or more ',' characters, the output will have thousand separators inserted between each group of three digits to the left of the decimal point. The placement and number of ',' characters in the format string does not affect the output, except to indicate that thousand separators are wanted.

E+

Scientific notation. If any of the strings 'E+', 'E-', 'e+', or 'e-' are contained in the format string, the number is formatted using scientific notation. A group of up to four '0' characters can immediately follow the 'E+', 'E-', 'e+', or 'e-' to determine the minimum number of digits in the exponent. The 'E+' and 'e+' formats cause a plus sign to be output for positive exponents and a minus sign to be output for negative exponents. The 'E-' and 'e-' formats output a sign character only for negative exponents.

Date/Time format

c

Displays the date using the format using the Short Date Format, followed by the time using the Long Time Format. The time is not displayed if the date-time value indicates midnight precisely.

d

Displays the day as a number without a leading zero (1-31).

dd

Displays the day as a number with a leading zero (01-31).

ddd

Displays the day as an abbreviation (Sun-Sat) using the strings of the Short Day Names.

dddd

Displays the day as a full name (Sunday-Saturday) using the strings of the Long Day Names.

ddddd

Displays the date using the Short Date Format.

dddddd

Displays the date using the Long Date Format.

e

Displays the year in the current period/era as a number without a leading zero (Japanese, Korean and Taiwanese locales only).

ee

Displays the year in the current period/era as a number with a leading zero (Japanese, Korean and Taiwanese locales only).

g

Displays the period/era as an abbreviation (Japanese and Taiwanese locales only).

gg

Displays the period/era as a full name. (Japanese and Taiwanese locales only).

m

Displays the month as a number without a leading zero (1-12). If the m specifier immediately follows an h or hh specifier, the minute rather than the month is displayed.

mm

Displays the month as a number with a leading zero (01-12). If the mm specifier immediately follows an h or hh specifier, the minute rather than the month is displayed.

mmm

Displays the month as an abbreviation (Jan-Dec) using the strings given of the Short Month Names.

mmmm

Displays the month as a full name (January-December) using the strings of the Long Month Names.

yy

Displays the year as a two-digit number (00-99).

yyyy

Displays the year as a four-digit number (0000-9999).

h

Displays the hour without a leading zero (0-23).

hh

Displays the hour with a leading zero (00-23).

n

Displays the minute without a leading zero (0-59).

nn

Displays the minute with a leading zero (00-59).

s

Displays the second without a leading zero (0-59).

ss

Displays the second with a leading zero (00-59).

z

Displays the millisecond without a leading zero (0-999).

zzz

Displays the millisecond with a leading zero (000-999).

t

Displays the time using the Short Time Format.

tt

Displays the time using the Long Time Format.

am/pm

Uses the 12-hour clock for the preceding h or hh specifier, and displays 'am' for any hour before noon, and 'pm' for any hour after noon. The am/pm specifier can use lower, upper, or mixed case, and the result is displayed accordingly.

a/p

Uses the 12-hour clock for the preceding h or hh specifier, and displays 'a' for any hour before noon, and 'p' for any hour after noon. The a/p specifier can use lower, upper, or mixed case, and the result is displayed accordingly.

ampm

Uses the 12-hour clock for the preceding h or hh specifier, and displays the contents of the TimeAMString global variable for any hour before noon, and the contents of the TimePMString global variable for any hour after noon.

/

Displays the date separator character using the Date Separator.

:

Displays the time separator character using the Time Separator.

'xx'/"xx"

Characters enclosed in single or double quotes are displayed as-is, and do not affect formatting.


Language Info Editor

The Language Info Editor dialog allows you to set the language name and specify the corresponding *.lng localization file. This dialog is opened when you add or edit a language (see Environment Options | Localization).

Language Name

The name of the language that is displayed in the Select Program Language dialog and within the Available Languages list of the Environment Options | Localization section.

Language File

The *.lng file containing the translated string resources. See the %program_directory%\Languages folder to find already existing localization files.

Adding a language

The Add language dialog allows you to specify your own localization file and set the language name.

Editing a language

The Edit language dialog allows you to change the language name or select another localization file for the specified language.


Using templates

For your convenience the ability to use templates is provided by SQL Manager for PostgreSQL. A template is a named collection of wizard options stored in a file.

Instead of performing a long chain of routine steps all the time you can save all the options of the wizard for future use as a template file. Select the Templates | Save Template drop-down menu item, specify the template file name and set an optional comment for the template file.

When starting the wizard next time, you can load the template by selecting the Templates | Load Template drop-down menu item.

Note that saving/loading of templates is possible at any step of the wizard.


Supported file formats

RadioButton MS Excel 97-2003

The most popular e-table format used by Microsoft® Excel (*.xls). The result files are fully compatible with Microsoft® Excel versions 97-2000, 2003 and XP.

RadioButton MS Access

File of Microsoft® Access format (*.mdb, *.accdb) with an ADO connection used.

RadioButton MS Word 97-2003

One of the most popular text processing formats used by Microsoft® Word (*.doc). The result files are fully compatible with Microsoft® Word versions 97-2000, 2003 and XP.

RadioButton RTF

Rich Text Format (*.rtf) supported by many text processing programs (e.g. WordPad).

RadioButton HTML

Hyper Text Markup Language file format (*.html, *.htm), complete compatibility with HTML 4.0 specification.

RadioButton PDF

A standard format in electronic publishing (*.pdf).

RadioButton Text file

Plain text file format (*.txt).

RadioButton CSV file

Comma-Separated Value file format (*.csv).

RadioButton DIF file

Data Interchange File (*.dif) format.

RadioButton SYLK

Symbolic Links (*.slk) file format.

Note: all the text formats including Text file, CSV, DIF, SYLK are usually used as working or interchange formats.

RadioButton LaTeX

A specific file format (*.tex) which is a popular (especially among mathematicians and physicists) macroextension of TeX pack developed by D.Knut.

RadioButton XML

A markup language for documents containing structured information (*.xml).

RadioButton DBF

Database file format (*.dbf) used by dBASE and a number of xBASE applications.

RadioButton MS Excel

The contemporary e-table format used by Microsoft® Excel (*.xlsx). The result files are fully compatible with Microsoft® Excel 2007.

RadioButton MS Word

The contemporary text processing format used by Microsoft® Word (*.docx). The result files are fully compatible with Microsoft® Word 2007.

RadioButton ODF Spreadsheets

OASIS Open Document Format for Office Applications - open document file format for spreadsheets (*.ods) used by a number of applications including OpenOffice.org and KOffice.

RadioButton ODF text

OASIS Open Document Format for Office Applications - open document file format for word processing (*.odt) documents used by a number of applications including OpenOffice.org and KOffice.


To-Do List

The To-Do List window allows you to make up a list of tasks for the database.

To call this window, select the View | To-Do List main menu item, or use the Shift+Ctrl+T shortcut.

The task list is displayed in a form of a grid. Its columns (Action, Priority, User, Category) correspond to the task parameters. Click the column caption to sort the task list by the current parameter or change the sorting direction. Use the Navigation bar and context menu to add, edit, and delete to-do items.

Appendix - To-Do List

Database

Select the database to apply the task list to. When switching between the databases you can view different task lists.

To add a task to this list, click the Add Item link on the Navigation bar, or select Add Item from the context menu. You can also use the Ins key for the same purpose. Define the task parameters and click OK to add the new task to the list.

Appendix - To-Do List - Edit To-Do item

Text

Optional text to describe the task.

Priority

Set a numeric value to indicate the priority of the task.

User Name

The database User name this task is applied to.

Category

Set a category for the task. Using categories may be useful for grouping tasks.

To modify a task, select the task in the list and click the Edit Item link of the Navigation bar, or select Edit Item in the context menu. You can also use the Enter key for the same purpose.

To remove a task, select the task in the list and click the Delete Item link of the Navigation bar, or select Delete Item in the context menu. You can also use the Del key for the same purpose.

To remove all tasks from To-Do List, click the Delete all link of the Navigation bar, or select Delete all in the context menu. You can also use the Ctrl+Del shortcut for the same purpose.


Windows List

The Windows List panel allows you to browse the list of windows that are currently opened within SQL Manager for PostgreSQL IDE.

To activate this panel as a DB Explorer tab, select the Windows | Window List main menu item, or use the Ctrl+Alt+0 shortcut.

Appendix - Window List

If necessary, you can right-click within the list area to call the popup menu which allows you to bring a window to foreground, close windows one by one or in groups, and to arrange the windows according to your preferences.


Customize toolbars and menus

For your convenience SQL Manager for PostgreSQL provides toolbars and menus that you can customize, so the commands you use frequently are readily available and easily identifiable.

The Customize dialog allows you to create and personalize SQL Manager menus and toolbars.

To call this dialog, click More buttons... btnMoreButtons on the right side of any toolbar, then click Add or Remove Buttons and select Customize... from the drop-down menu. Alternatively, you can right-click any toolbar and select the Customize... popup menu item.

Toolbars

Toolbars

This list displays all currently existing toolbars of SQL Manager (both default and user-defined toolbars). Check/uncheck the box at a toolbar name to show/hide the toolbar.

New...

Use this button to add a new user-defined toolbar to the Toolbars list. Set a name for the newly created toolbar and dock it by dragging it to any permitted location within the application window.

Rename...

Use this button to rename the selected user-defined toolbar.

Delete

Use this button to delete the selected user-defined toolbar.

Appendix - Customize - Toolbars

Commands

This tab allows you to browse the list of all commands available within the menus and toolbars of the application window. Selecting categories in the Categories list displays commands of the selected category (e.g. 'Database' or 'Tools') in the Commands list.

If necessary, you can pick a command and drag it to any toolbar to create a button for this command.

Appendix - Customize - Commands

Options

Personalized Menus and Toolbars

CheckBox Menus show recently used commands first

This option determines whether the most frequently used items will be placed in menus at first position.

If this option is enabled, frequently used menu items are "promoted" and displayed higher on the list. Unused and infrequently used menu items are visually suppressed and appear "collapsed".

CheckBox Show full menus after a short delay

This option is available only if the Menus show recently used commands first option is selected.

If this option is enabled, infrequently used menu items (if they appear "collapsed") will be automatically expanded after a delay upon setting mouse cursor (or upon selection with the Up/Down keys) on the bottom of the menu. Otherwise, the menu expands only after clicking its bottom-most button (or using the Ctrl+Down shortcut).

Reset my usage data

Resets the lists of recently used commands in the toolbars and menus.

Appendix - Customize - Options

Other

CheckBox Large icons

This option displays larger icons on the parent window toolbars.

CheckBox Show ToolTips on toolbars

If this option is selected, ToolTips (hints) popup when the mouse cursor is positioned over a toolbar button.

CheckBox Show shortcut keys in ToolTips

If this option is selected, the corresponding shortcuts are displayed in ToolTips (hints) for toolbar buttons.

Menu animations

Use the drop-down list to specify the menu animation effects:

None (no animation)

Random (random choice: Unfold, Slide, Fade)

Unfold (unfolding menus)

Slide (sliding menus)

Fade (menus fade in when appearing)


SSH tunneling options

SSH (Secure Shell Host) protocol is used to heighten computer security when working with Unix systems on the Internet. SSH uses several encryption algorithms of different reliability. The spread of SSH is also related to the fact that a number of *nix operating systems (e.g. FreeBSD) include SSH server in their standard distributions. To learn more about SSH, please visit http://openssh.org.

The SSH tunneling feature of SQL Manager is a means of ensuring secure connection to PostgreSQL servers when working over insecure connection channels. You can also use SSH tunnel to get access to the remote PostgreSQL servers when port 3306 is closed for external connections for some reasons.

The connection via SSH tunnel works in the following way.

First, a connection is established and the process of authentication between SSH client built in SQL Manager and remote PostgreSQL server is performed. Then all incoming and outgoing information between the application and PostgreSQL is transmitted through SSH server with the help of a communication port (regularly port 22), and SSH server transfers this information directly to PostgreSQL server.

To setup the connection via SSH tunnel, input the following values in the corresponding fields:

  • SSH host name is the name of the host where SSH server is running
  • SSH port indicates the port where SSH server is activated
  • SSH user name stands for the user on the machine where SSH server is running (Note: it is a Linux/Windows user, not a user of PostgreSQL server)
  • SSH password is the Linux/Windows user password

Please note that PostgreSQL host name should be set relatively to the SSH server in this case. For example, if both PostgreSQL and SSH servers are located on the same computer, you should specify localhost as host name instead of the server external host name or IP address.

Appendix - SSH tunneling options

CheckBox Use Private Key for authentication

If the SSH encryption is enabled on the SSH server, a user can generate a pair of cryptographic keys (the Private key and the Public key). The Public key is placed on the SSH server, and the Private key is the part you keep secret inside a secure box that can only be opened with the correct passphrase (or an empty string as the passphrase). When you wish to access the remote system, you open the secure box with your passphrase (if any), and use the private key to authenticate yourself with the Public key on the remote Linux computer.

SSH Key file

Specify the location (the secure box) of the Private key file on your local machine.

Supported Private Key file formats are:

OpenSSH

Putty

SSH.com

Note that you need to trust your local machine not to scrape your passphrase or a copy of your Private key file while it is out of its secure box.

SSH Private Key - Passphrase


HTTP tunneling options

HTTP tunneling is a method that allows one to connect to a database and transmit data between the program and a PostgreSQL server through the HTTP/HTTPS protocols using port 80 which is used by a regular Internet browser. This method is used to connect to the remote PostgreSQL server of a hosting company when direct connection is not available (e.g. for security reasons).

The HTTP tunnel works in the following way.

All outgoing queries and commands sent by the client's software are encoded and transmitted through the HTTP/HTTPS protocol using port 80 to the special script that decodes the received data, sends it to PostgreSQL server for processing and then sends the result back. This method requires the HTTP server (Apache) and PHP with PostgreSQL to be installed on the remote server. Normally this software is provided by a hosting company that offers Linux hosting solutions.

To use HTTP tunneling, just upload the tunneling script to the webserver where PostgreSQL server is located (e.g. to the location where other PHP scripts are stored), or to any other webserver from which direct connections to your PostgreSQL server are allowed. This script exposes the PostgreSQL API as a set of web-services used by SQL Manager for PostgreSQL.

If your webserver complies with the requirements and the script is installed correctly, you will see the message "EmsProxy v 1.31" (version can be different) in your browser when opening the http://<your_webserver>/emsproxy.php page.

In case of using this connection method the response will be slower as compared to the direct connection or the SSH Tunneling method, since the data are XML encoded and HTTP is stateless by nature. However, all the features of SQL Manager for PostgreSQL are available.

Note that the emsproxy.php script file is included into the distribution package and can be found in SQL Manager installation directory.

Appendix - HTTP tunneling options


SQL Manager Direct

SQL Manager Direct is a feature of SQL Manager for PostgreSQL which provides you with quick access to the related Internet resources and allows you to keep your SQL Manager version up-to-date.

To open the SQL Manager Direct window, select the Help | SQL Manager Direct item from the main menu.

Links to sqlmanager.net resources provided by the SQL Manager Direct window are grouped into several sections:

  • SQL Manager for PostgreSQL News
  • General Information
  • Downloads
  • Related Products

Upon a link selection you will be immediately forwarded to the corresponding resource.

SQL Manager for PostgreSQL News

This section takes you directly to the latest EMS news column. Using the links you can get up-to-date news, product information and downloads from sqlmanager.net.

General Information

This section offers a number of links to product news, features, Feature Matrix, system requirements, testimonials and much more.

Downloads

Using links of this section you can download other product versions from the download page.

Related Products

This section allows you to browse the list of related products developed by EMS Database Management Solutions, Inc.

Appendix - SQL Manager Direct

Use the btnBack btnForward buttons to navigate in the same way as you normally do it using a web browser.

Click the Update button to refresh the page.

CheckBox Automatically poll network in interval (in days)

If this option is selected, the page is refreshed automatically after the specified time interval. Use the spinner control to set the interval (in days).

In the Status area at the bottom of the SQL Manager Direct window you can find the status of your request to the sqlmanager.net website.


Database Login dialog

The Database Login dialog appears on attempt to connect to a database if the Login prompt before connection option is enabled on the Options page of the Database Registration Info dialog.

Appendix - Database Login

Note: If SSH tunneling is used for the database connection, the SSH Login dialog with the SSH user name and SSH password boxes appears first.

Specify SSH user name / password (if necessary), user name / password and click OK to start working with the database.


Overwriting existing output file

If a file having the same name as specified for an output file generated by SQL Manager already exists, a warning dialog is displayed.

Appendix - Overwrite File Warning dialog

You can Overwrite the file, Make it Unique, or Cancel both and change the path or file name manually.

The application makes the file unique by adding the current timestamp to the specified file name if the CheckBox Add Timestamp to filename option is enabled, or by adding a simple numeric postfix to the file name if this option is disabled.


Script conversion

The Script conversion dialog allows you to select encoding to be used for script conversion upon loading script to one of SQL Manager editors (Query Data, Execute Script Editor) from an external file.

Appendix - Script conversion

RadioButton Windows default

Specifies that the standard Windows encoding will be used for the script conversion.

RadioButton Database default

Specifies that the default encoding of the database will be used for the script conversion.

RadioButton Other encoding

Allows you to select the encoding that will be used for the script conversion.

Preview

This area displays the script with the current encoding parameters applied.


Select Object dialog

The Select Object dialog appears each time the application requests a database object selection, e.g. upon a root object selection for the Dependency Tree tool, or when choosing an object to be added to a project.

Dependency Tree - Select object

First select the object type in the list on the left-hand side of the window. Use the drop-down list at the top to select the schema, pick the object you need and click OK the apply your selection.


SQL Manager shortcuts

Database management

Shift+Alt+R | Register a database using Register Database Wizard
Shift+Alt+U | Unregister the selected database
Shift+Ctrl+C | Connect to a database
Shift+Ctrl+D | Disconnect from a database

Database objects management

Ctrl+N | Create a new object (the object type depends on the current selection)
Ctrl+O | Edit the selected object in its editor
Ctrl+R | Rename the selected object
Shift+Del | Drop the selected object
Ctrl+Shift+C | Collapse the current DB Explorer tree branch and switch selection to the parent tree node

SQL Manager tools

F11 | View/hide Database Explorer
Ctrl+F | Search for an item in the DB Explorer tree
Shift+Ctrl+T | Open the To-Do List window
F12 | Show Query Data
Shift+F12 | Open a new instance of Query Data
Shift+Ctrl+M | Open SQL Monitor
Shift+Ctrl+S | Open Execute Script Editor
Shift+Ctrl+L | Open Localization Editor
Ins | Add a new table subobject (the subobject type depends on the current tab selection)
Ctrl+Ins | Add a parameter in Function Editor
Ctrl+Del | Remove a parameter in Function Editor
Ctrl+Up | Move an argument up in Function Editor
Ctrl+Down | Move an argument down in Function Editor
Ctrl+I | Start incremental search

Query Data and Execute Script (fixed and default)

F9 | Execute query/script
Alt+F9 | Execute selected only
Ctrl+Alt+F9 | Execute under cursor
Ctrl+Alt+F2 | Reset execution point (Query Data only)
Shift+Ctrl+<digit> | Toggle bookmark #<digit>
Ctrl+<digit> | Go to bookmark #<digit>
Ctrl+Q,N | Go to next bookmark
Ctrl+Q,P | Go to previous bookmark
F2 | Drop marker to current position
Esc | Collect marker (jump back)
Shift+Esc | Swap marker to current position
Ctrl+Z; Alt+BkSp | Undo
Shift+Ctrl+Z; Shift+Alt+BkSp | Redo
Ctrl+F | Search for text using the Find Text dialog
Ctrl+R | Replace text using the Replace Text dialog
F3 | Search next
Ctrl+I | Start incremental search
Alt+G | Go to line number (an input number dialog prompts for the number)
Ctrl+L | Load a script from an external file
Ctrl+S | Load the script to an external file
Shift+Ctrl+F | Format the SQL text using SQL Formatter
Alt+<symbol> | Switch to the query with <&symbol> in its name (Query Data only)
Ctrl+J | Insert a keyboard template
Ctrl+D | Toggle query results display mode (at the Edit tab or at a separate one)
Ctrl+Alt+Left | Switch to the next tab of Query Data
Ctrl+Alt+Right | Switch to the previous tab of Query Data
Ctrl+Alt+PgUp | Switch to the last tab of Query Data
Ctrl+Alt+PgDown | Switch to the first tab of Query Data
Ctrl+Q,S | Move cursor to beginning of line
Ctrl+Q,D | Move cursor to end of line
Ctrl+Q,R | Move cursor to absolute beginning
Ctrl+Q,C | Move cursor to absolute end
Ctrl+O,N | Normal selection mode
Ctrl+O,L | Line selection mode
Ctrl+O,C | Column selection mode
Shift+Ctrl+Left | Select the previous word
Shift+Ctrl+Right | Select the next word
Shift+Home | Select text to the beginning of the line
Shift+End | Select text to the end of the line
Shift+PageUp | Select one page up
Shift+PageDown | Select one page down
Shift+Ctrl+PageUp | Select text to the first line on the page
Shift+Ctrl+PageDown | Select text to the last line on the page
Shift+Ctrl+Home | Select text to the absolute beginning
Shift+Ctrl+End | Select text to the absolute end
Shift+Alt+Left | Select column symbol-by-symbol to the left
Shift+Alt+Right | Select column symbol-by-symbol to the right
Shift+Alt+Up | Select column upwards
Shift+Alt+Down | Select column downwards
Shift+Ctrl+Alt+Left | Select column word-by-word to the left
Shift+Ctrl+Alt+Right | Select column word-by-word to the right
Shift+Alt+Home | Select column to the beginning of line
Shift+Alt+End | Select column to the end of line
Shift+Alt+PageUp | Select column to the beginning of the page
Shift+Alt+PageDown | Select column to the end of the page
Shift+Ctrl+Alt+Home | Select column from the current cursor position to the beginning of the first line
Shift+Ctrl+Alt+End | Select column from the current cursor position to the beginning of the last line
Ctrl+Up | Scroll up one line with cursor position unchanged
Ctrl+Down | Scroll down one line with cursor position unchanged
Alt+Down, Alt+Up | Toggle case of a current word
Ctrl+Alt+Up | Toggle case to upper of a current selection or char
Ctrl+Alt+Down | Toggle case to lower of a current selection or char
Ctrl+G+T | Toggle folding
Ctrl+G,Ctrl+F | Collapse block at current line
Ctrl+G,Ctrl+E | Expand block at current line
Ctrl+G,Ctrl+C | Collapse/Expand block at current line
Ctrl+G,Ctrl+M | Collapse all blocks in the text
Ctrl+G,Ctrl+P | Expand all blocks in the text
Ctrl+= | Collapse/expand the nearest block
Shift+Ctrl+B | Jump to matching bracket (change range side)
Shift+Ctrl+I | Indent selected block
Shift+Ctrl+U; Shift+Tab | Unindent selected block
Ctrl+/ | Comment/uncomment selected block
Ctrl+Space | Show code completion
Ctrl+Alt+Space | Show character map
Ctrl+Shift+Space | Show code parameters
Ctrl+Alt+Q | Show columns
Ctrl+Alt+T | Show tables
Ctrl+Alt+V | Show views
Ctrl+Alt+U | Show functions
Ctrl+Alt+J | Show domains
Ctrl+Alt+G | Show triggers
Ctrl+Alt+X | Show indices
Ctrl+Alt+S | Show sequences
Ctrl+Alt+M | Show composite types
Ctrl+Alt+E | Show enum types
Ctrl+Alt+Y | Show base types
Ctrl+Alt+A | Show aggregates
Ctrl+Alt+O | Show operators
Ctrl+Alt+N | Show collations
Ctrl+Alt+L | Show languages
Ctrl+Alt+P | Show tablespaces
Ctrl+C; Ctrl+Ins | Copy selection to Clipboard
Ctrl+X; Shift+Del | Cut selection to Clipboard
Ctrl+V; Shift+Ins | Paste Clipboard to current position
Ctrl+Del | Delete from cursor to the next word
Ctrl+BkSp | Delete from cursor to the end of the previous word
Ctrl+B | Delete from cursor to the beginning of the line
Shift+Ctrl+Y | Delete from cursor to the end of the line
Ctrl+Y | Delete the current line
Ctrl+M; Enter; Shift+Enter | Break line at current position, move caret to a new line
Ctrl+Alt+I | Insert Tab char
Shift+Ctrl+R | Start macro recording
Shift+Ctrl+P | Play macro
Alt+End | Skip misprint
Ctrl+Alt+End | Skip all misprints
Alt+Home | Correct all misprints
F5 | Toggle breakpoint
Shift+F5 | Enable breakpoint

Print Data View

Ctrl+O | Load a printing report from a file
Ctrl+S | Save the report to file
Ctrl+P | Open the Print dialog
Ctrl+Home | Go to the first page
Ctrl+Up | Go to the previous page
Ctrl+Down | Go to the next page
Ctrl+End | Go to the last page
Ctrl+D | Open Report Formatter
Ctrl+\ | Zoom 100%
Ctrl+0 | Zoom page width
Ctrl+1 | Whole page
Ctrl+2 | Two pages
Ctrl+4 | Four pages
Ctrl+W | Widen to source width
Ctrl+M | Show/hide margins
Ctrl+K | Set background color for the report

Working with windows, menus and tabs

Ctrl+Tab | Switch to the next tab
Ctrl+Alt-0 | Open Windows List
Ctrl+Alt+D | Set defaults to all windows
Ctrl+F6 | Switch to the previous window
F6 | Switch to the next window
Ctrl+W | Close the active window
Ctrl+Down | Expand a collapsed menu
Ctrl+Shift+N | Move to the next tab in DB Explorer
Ctrl+Shift+P | Move to the previous tab in DB Explorer


How to...

The succeeding pages of this chapter are intended to provide you with brief instructions on how to perform this or that operation correctly using SQL Manager for PostgreSQL.

Work with databases

Connect to a database

Create a database

Edit database connection parameters

Make work with a database faster

Design a visual database structure

View an ER diagram

Create a database copy

Document a database

Save metadata reports to file

Log database changes

Get an SQL dump

Synchronize two databases

Work with database objects

Group objects

Find objects

View dependecies

Get an object DDL

Work with data

View tables with many records

Set data filter

Sort and group data

Export/import data

Export data as Execute Script

Edit data of master-detail tables

Add image to table

Set data display format

Work with queries and scripts

Create SQL statements rapidly

Control a query productivity

Work with several queries at once

Save most frequently used queries

Execute queries with parameters

Export query results into file

Execute scripts

Execute a large SQL script

Make SQL script work faster

Customize work with Query/Script text

View executed queries and scripts

Work with version control

Enable version control

Create the repository for your database from scratch

Rollback to previous revision state

View database changes

View procedure changes

Create a simple report in Report Designer

Transfer program settings

Update SQL Manager

Report bugs and suggestions


Connect to a database

If you want to connect to a database that has not been registered yet then perform the following operations:

  1. Launch the Register Database wizard by selecting the Database | btnRegisterDB Register Database... main menu item.
  2. If a host where the database is located has not been registered yet then type in its name in the Host name field on the first step of the wizard. Otherwise, select the necessary host from the drop-down list. If needed you can set Tunneling parameters as well.

Note: To register several databases at once uncheck the CheckBox Register a single database option. In this case you will proceed to the Selecting databases step of the wizard where you are to define databases you want to be registered.

  3. On the last step of the wizard set database name and specify specific options.
  4. The registered database(s) is/are now displayed in the DB Explorer. To connect to the database double-click its alias or select the btnConnectToDB Connect to Database item of the database context menu.


Create a database

To create a database on the registered server perform the following operations:

  1. Launch the Create Database wizard by selecting Database | btnCreateDB Create Database main menu item.
  2. On the first step specify a name for a newly created database.
  3. On the second step set the necessary connection properties for the database being created. Use the corresponding boxes and options: Host name, Port, User name and Password. If needed you can set Tunneling parameters as well.
  4. If you want your newly created database to contain data of another database then select it from the Template drop-down list situated on the Setting advanced database properties step. There you can also specify such properties as Encoding, Owner, Default tablespace and Connection limit.
  5. On the last step view the result SQL statement. If you have checked the CheckBox Register After Creating box on the first step of the wizard then the Database Registration Info dialog will appear after creating a new database.


Edit database connection parameters

If you have made a mistake when creating or registering a database or the information provided is incomplete then it can be edited using the Database Registration Info dialog. You can view this information both for connected or disconnected database.

To open the dialog, select the database or any of its objects in the DB Explorer tree, then select the Database | btnDBRegistrationInfo Database Registration Info... main menu item, or right-click the database alias in DB Explorer and use the btnDBRegistrationInfo Database Registration Info... context menu item.

The connection parameters can be changed on the Connections tab of the dialog. Here you can define or redefine the following properties in the corresponding boxes: Server name, User name, Password, Database name, Database alias and Font charset.


Make work with a database faster

If your database contains too many objects or if connection to the database is slow you can increase work speed by uncheking the CheckBox Refresh objects on connection option when registering database or editing the Database Registration Info.


Design a visual database structure

To design your database visually you may use the Database Designer. It allows you to create, edit and drop tables and table columns, set relations between tables and perform other operations you may need to achieve your purpose. All new objects are displayed on a diagram.


View an ER diagram

The relationship diagram is built using the reverse engineering operation.

To view an ER diagram of a scheme you should follow the steps:

  1. Run Database Designer;
  2. Click the btnReverseEngineer Reverse Engineer button on the main toolbar or use the corresponding item of the context menu.
  3. Choose schemas to reverse engineer from.

The created diagram can be saved as a *.pgd file ( btnSave Save Diagram button) or as an image ( btnSaveAsPicture Save as Picture button).


Create a database copy

In order to create a copy of the whole database or of separate objects you can:

  1. Extract DB objects structure and data into SQL script using the Extract Database Wizard. The result script can be used to copy or restore your database.
  2. Create database backups with the help of the Backup Database Wizard.
  3. Create copies of separate database objects by using the Duplicate Object Wizard.
  4. Copy the selected database wholly or partially to a new database or to one of the existing databases using the Copy Database Wizard.


Document a database

There are several ways to document a database:

  1. You can generate a detailed HTML report of the selected database objects using HTML Report Wizard.
  2. You can generate and print metadata reports of any database object(s). Generated reports can be exported to any of the available formats: HTML file, Excel file, Text file, RTF file, CSV file, HTML file, BMP image, Excel table (OLE), JPEG image, TIFF image.
  3. You can save the Database Designer diagram as a *.pgd file for future use. If necessary, you can also save the diagram as an image.


Save metadata reports to file

To save a metadata report in a file of any supported format (*.txt, *.csv, *.pdf, *.html) you should do the following:

  1. Open the Print Metadata window by selecting the Tools | iconPrint Print Metadata item of the main menu.
  2. Mark the needed objects and define printing settings and click the btnPrintPreview Preview button on the navigation bar or toolbar.
  3. In the opened Preview window click btnPreviewExport Export and select from the drop-down list the needed file format for report saving. When done, specify file name and location.


Log database changes

If you want to perform metadata changes logging and SQL query logging you need to:

  1. Check the CheckBox Enable log of metadata changes and specify the path to the *.sql file to store the metadata logs.
  2. Check the CheckBox Enable log of Query Data queries and specify the path to the *.sql file to store the logs of SQL queries: date/time of query execution, SQL text, execution result or errors (if any).

This can be done in the Database Registration Info | Logs window.


Get an SQL dump

To get an SQL dump (an *.sql file) of your database use the Extract Database Wizard that will extract database objects and/or data to an SQL script, e.g. for backup purposes.


Synchronize two databases

The synchronization between two databases can be done with a help of the Compare Databases Wizard. This wizard allows you to compare databases and create a script to deploy changes from one database into another one.

To run the wizard use the Tools | iconCompare Compare Databases... item of the main menu.


Group objects

If you want to group objects you can do it in one of the following ways:

  • Using projects (situated in the DB Explorer tree):
  1. Click create New Sub Folder in the Projects folder using the corresponding item of the context menu
  2. Define its name and drag-and-drop necessary objects there or use the Add Object item of the created folder context menu. Pick the objects to add to folder from the appeared dialog.
  • Using DB Explorer tabs:
  1. Right-click the necessary object in the DB Explorer.
  2. Choose the btnNewTabFromHere New Tab from Here item of the object context menu and define the name of the tab.
  3. Now your objects are stored on the separate tab of a DB Explorer.

Note: If an object is not a tree node, it cannot be placed on a separate tab.


Find objects

In order to search for objects you need you can:

  1. Call the Find Object dialog by right-clicking the Database alias, any database object group nodes or objects in the DB Explorer tree and select the Find Object... context menu item.
  2. Call the Find Object dialog by using the Ctrl+F shortcut.
  3. Type in the first letters in the edit-box of the Search Panel, and the corresponding object will be highlighted in the tree.

Note: Objects among which the search is performed should be updated and the object node should be expanded.

  4. Launch the Search in Metadata tool by selecting the Tools | iconSearchInMetadata Search in Metadata main menu item, or using the Ctrl+Alt+F shortcut. After the search is complete, the Explorer group on the Navigation bar displays the tree of database objects in which the search string is found, and allows you to view metadata of the required object or its fragment.


View dependecies

If you want to view all the object dependencies then:

  1. Use a dependencies tab in the Table Editor.
  2. Use the Dependency Tree tool.

These tools may be useful when you can't find an object that prevents your from dropping a table.


Get an object DDL

In order to get an object DDL you can:

  1. Right-click the object in the DB explorer tree and select the Script to New Query Data | Create context menu item.
  2. Right-click the object and select the Edit Table <table_name>... context menu item or double-click the table and then proceed to the DDL tab in the opened table editor window.
  3. Right-click the object in the DB explorer tree and select the Data Manipulation | Export Data as SQL Script context menu item.


View tables with many records

If your table contains a lot of records you can minimize dataset loading time by:

  1. Setting the number of records to be selected;
  2. Enabling RadioButton Load visible records in order to load only a fixed number of dataset records into memory

These options can be set only for the selected database on the Data Options page of the Database Registration Info.

Default settings for newly registered databases can be defined on the Grid | Data Options page of the Environment Options dialog.


Set data filter

Quick Filtering (by the current value in a cell)

Open the context menu of the needed column and choose the Quick Filter item. Then choose a filter condition in the opened submenu.

Filtering by Column

HowTo - Grid View - Quick Filter

Open the drop-down list on the column title and choose a filter condition from the list.

You can set advanced conditions by using the Custom... menu item.

When choosing this item, the special window for setting filter conditions opens.

Advanced Filtering

You can set advanced filter options by pressing the button btnSetFilter on the toolbar of the Data View and set filter parameters in the Filter Builder. Apply the set conditions by pressing the Apply button.

If a filter is set for a table, the special bar appears in the lower part of the table where you can see filter conditions and the history of filter changes opened by pressing the drop-down list.

Data View - Grid View - Filtering records - Filtering panel

Disable Filtering

To cancel filtering, open the context menu of the column and choose the Disable filter item.

Or press the btnClose button on the filter toolbar.


Sort and group data

In order to sort data, do the following:

  1. Open data at the Data or Results tab.
  2. Choose the column by which you need to sort data and click the column title.
  3. If the column was not sorted, the first click will sort it in the ascending order and the second one - in the descending order.

Note: To cancel the sorting, open the context menu by right-clicking the necessary column and choose the Clear Sorting item, or press the Ctrl button and click the column title.

To enable grouping, drag the column title to the special grouping car above the table.

HowTo - Data View - Grid View - Grouping data by two columns_Small

Note: To disable grouping, drag the column title from the group bar back to the table.


Export/import data

You can export data from a database table into an external file of any supported format by means of the Export Data Wizard. There are several ways to launch it:

  1. Open the Data or Results tab, press [image] Export Data on one of the Data View toolbars.
  2. Open the Data or Results tab, choose Data Manipulation | Export Data in the Data Grid context menu.
  3. Open the table context menu in the DB Explorer, choose the Data Manipulation | Export Data item.
  4. Open the Data or Results tab and use the shortcut Shift+Ctrl+E.

You can import data from external sources into a table or view using the Import Data Wizard:

  1. Open the Data tab, press the Import Data button on one of the Data View toolbar.
  2. Open the Data tab, choose Data Manipulation | Import Data in the Data Grid context menu.
  3. Open the table context menu in the DB Explorer, choose the Import Data item.
  4. Open the Data tab and use the shortcut Ctrl+I.

Note: Export and import data tools are available in full version of SQL Manager for PostgreSQL only.


Export data as SQL script

You can export data from a database table into SQL script with INSERT INTO statements in one of the following ways:

  1. Open the Data or Results tab, press the [image] Export Data as SQL Script on one of the Data View toolbars and set export parameters in the opened Export as SQL Script Wizard.
  2. Open the Data or Results tab, choose Data Manipulation | [image] Export Data as SQL Script in the Data Grid context menu and set export parameters in the opened Export as SQL Script Wizard.
  3. Open the table context menu in the DB Explorer, choose the Data Manipulation | [image] Export Data as SQL Script item and set export parameters in the opened Export as SQL Script Wizard.

Note: In order to extract table DDL (CREATE TABLE statement), check the CheckBox Add CREATE TABLE statement box at the Step 1.


Edit data of master-detail tables

You can work with data in multi-level mode, that is you can view and modify it in several related tables simultaneously.

To manage grid levels, right-click the grid and select the Grid Levels context menu group. Click Add Grid Level in the menu to run the Create Grid Level wizard. After the level is added you can edit data of the related tables.


Add image to table

If you want to add an image to a table then do the following:

  1. Open the table on the Data tab.
  2. Go to the BLOB View section (the navigation buttons are located in the bottom part of the window) and then proceed to the Image tab.
  3. If there are several BLOB columns, choose the required column from the Select BLOB Column drop-down list on the toolbar of the Blob View tab and press the iconLoadFromFile Load from File button on the same toolbar.
  4. Choose the needed image file in the appeared dialog.

HowTo - Grid View - BLOBView - Select BLOB Column

Note: Adding images to table is possible only if table contains at least one BLOB column.


Set data display format

To set the format for displaying data open the Options | btnEnvironmentOptions Environment Options dialog from the main program menu, proceed to the Color & Formats tab and define or choose the display format for some data types in the Display formats section.


Create SQL statements rapidly

There are two options for creating SQL queries rapidly:

In the DB Explorer

  1. Right-click a table in the DB Explorer
  2. Choose Script to New Query Data context menu item.
  3. Select the necessary query type.

In the Visual Design Query

  1. Open Design Query.
  2. On the Builder tab drag an object from the DB Explorer tree to the diagram area.
  3. Choose necessary columns to include in the query by checking the corresponding box located to the left from the column name in the list, or just by double-clicking it. To include all columns of the table/view, check the box located to the left of the table/view caption.
  4. Associate two objects by their columns. Drag a column from one object list to another. This will set a link between these objects by the selected columns. It is indicated by a bidirectional arrow between the linked columns.
  5. Edit link properties. Double-click the linking arrow or right-click it and select the Property popup menu item. The Link properties dialog allows you to change the association condition by choosing it from the drop-down list.
  6. You can view and edit your SQL statement on the Edit tab of the Design Query.


Control a query productivity

You can view a query productivity on the query plan. It allows you to view the sequence of actions performed by the database server in the process of the query execution, and the amount of system resources used for the query execution.

To view the Plan of a query, open the query in Query Data and use the btnExplainQuery Show estimated execution plan item of the Navigation bar or toolbar.

If necessary, you can specify that the Plan tab appears automatically upon query execution in Query Data: select the CheckBox Show actual execution plan on query execution option available within the Tools | Query Data section of the Environment Options dialog.


Work with several queries at once

Query Data provides a possibility to open and edit several queries. You can create tabs in the lower part of the Query Data, each tab may contain a separate query. There are several ways for creating tabs:

  1. Open btnShowSQLEditor Query Data and choose btnNewSQLEditor Add New Query on one of the toolbars.
  2. Open btnShowSQLEditor Query Data and choose btnNewSQLEditor Add New Query in the context menu of the existing tab. HowTo - WorkWithQueries - AddNewQuery
  3. Use the shortcut Ctrl + N.

Note: Each tab can be renamed and any query can be added to Favorite Queries.


Save most frequently used queries

Use the Favorite Queries feature to store your most frequently used SQL queries. To access the list of your favorite queries you can use the Favorite Queries node of DB Explorer or create a separate tab for your Favorite queries.

Using the context menu you can create a new Favorite query or edit an existing one using Favorites editor, open any of the existing queries in Query Data or remove a query if you don't need it any longer.


Execute queries with parameters

If you want to use queries with parameters then you should check CheckBox Allow using parameters in query text option in the Environment Options | Tools.

This feature allows you to specify different values within a query in a popup dialog just before the query execution. Use the colon (':') character before an identifier (e.g. :P1) to specify a parameter within the query.


Export query results into file

When executing queries, their results can be displayed on the Edit or Results tab in the Data View.

You can copy data from database tables into an external file of any supported format in one of the following ways:

  1. Open the Data or Results tab, press [image] Export Data on one of the Data View toolbars and define export parameters in the opened Data Export Wizard.
  2. Open the Data or Results tab, choose Data Manipulation | [image] Export Data in the Data Grid context menu and define export parameters in the opened Data Export Wizard.
  3. Open the table context menu in the DB Explorer, choose the [image] Export Data item and define export parameters in the opened Data Export Wizard.
  4. Open the Data or Results tab and use the shortcut Ctrl+E.


Execute scripts

Execute Script allows you to create, view, edit and execute SQL scripts. To open Execute Script Editor select the Tools | btnShowSQLScript Execute Script... main menu item. This tool is intended for work with a great number of SQL statements and with scripts that are stored in files. For instance, you can execute a script directly from a file without loading it to the Editor window. This reduces memory usage. However Execute Script allows just to estimate whether the execution of script statements will be successful, but it does not return query result.

Note: To execute SQL scripts you should use Execute Script, not Query Data. The latter is intended for creating, editing and executing SQL statements. It also provides a possibility to view query result, perform various operations with it (data import, data export, etc.) and manage transactions.


Execute a large SQL script

If you need to execute a large SQL script it's not necessary to load it from file to the Execute Script Editor window as it can take a lot of time. Instead you can execute script directly from *.sql, *.zsql or *.txt file. In order to do this click the iconCompile Execute script from file button of the Navigation bar and Toolbar in Execute Script editor.


Make SQL script work faster

In order to make the SQL script work faster, you can disable some functions.

Parsing

Choose and disable the iconDBExplorer Disable Parsing item on one of Execute Script Editor toolbars.

Automatic Creation of Hierarchical Text Structure

Uncheck the CheckBox Use code folding box on the Display tab of the Editor options.

Syntax Highlight and Quick Code for Aliases

Choose Options | Editor options in the main menu, proceed to the General tab and uncheck the CheckBox Resolve aliases box - the syntax highlight and quick code for aliases will be disabled.


Customize work with query/script text

Using Internal Link

The name of the object existing on a database is highlighted in a query/script text. You can open such an object by holding the Ctrl key and clicking the object with a mouse.

Adding Text Template

To add a keyboard template, use Ctrl+J shortcut.

Automatic Completion (Object List)

You can call the autocompletion list by starting to enter the first characters of the text and using the shortcut Ctrl + Space.

Customize Autocompletion List

Choose Options | Editor options in the main program menu, proceed to the Code Completion tab and define the list and quick code parameters.

Automatic Formatting of Query/Script

Choose Quick Code | Format in the Query Data/Execute Script context menu or the Shift+Ctrl+F shortcut to apply automatic formatting.

Setting Font and Query/Script Format at the Display tab

Choose Options | Editor options in the main program menu, proceed to the Display tab and define common font and format parameters for Query Data/Execute Script.

Setting Font and Query/Script Format at the Highlight tab

Choose Options | Editor options in the main program menu, proceed to the Color Scheme tab and define font options for each element.

Note: If some font parameters are defined on the Highlight tab, they will be applied to the query/script text and not the ones defined on the Display tab.


View executed queries and scripts

To view all queries and scripts sent to the server you need to launch SQL Monitor. It will show you the log of database operations and SQL queries as items, each consisting of 3 parts: Executed (the date and time of the operation), Operation (SQL statement sent to the server), Result (the result of the operation).

Note: SQL Monitor only displays scripts and queries executed in SQL Manager for PostgreSQL during the current session.


Work with Version Control

Change management system allows you to:

  • Systematization of release database new versions process: storing different database versions; tracking of database changes; Getting (storing, testing) change scripts which reveal differences between two database states.
  • Possibility to rollback database to definite state.
  • Control of database changes.

When a user of the system makes typical actions, such as getting previous version of a document or creating new version etc., he works with a local copy of repository. As the amount of applied changes grows, repositories of various developers become more different. This results in necessity of synchronization of repositories. Synchronization can be performed by interchange of patches or change sets among developers.


Enable version control

SQL Manager for PostgreSQL
  • Index
  • « Prev
  • Next »

Enabling version control

To start working with Version Control System (VCS) you need to:

  1. Install change management system.

The following systems are supported:

  • CVS
  • Subversion
  • Microsoft Visual SourceSafe
  • Team Foundation Server
  2. Create the directory for CVS and Subversion, which is a working copy of VCS (version control system) directory.
  3. Open the Change Management tab of the Database Registration Info dialog to check the CheckBox Enabled flag.
  4. Create local repository for each database under version control. Press the Repository Management Wizard button to open the corresponding wizard. Use this wizard to define settings for linking database to VCS repository. Repository is a directory, where VCS stores all documents with history of its changes and other service information.
  5. Specify the parameters of the created repository at the Change Management tab of the database registration info dialog, or confirm autocomplete on closing the Repository management wizard.
  6. Confirm the changes and reconnect to the database.

You can view/edit repository connection settings within the Provider settings dialog which can be called by pressing the Properties button.


Create the repository for a database from scratch

If you have just installed Subversion (please note that SQL Manager supports CollabNet Subversion and Slik Subversion only), and you need to create the repository for your database from scratch, please perform the following.

  1. You need to initialize the SVN server repository. To do this, use native Subversion 'svnadmin' tool which is included into subversion server installation. Please execute the following command: <msg:code>svnadmin create c:\svnstorage\</msg:code> specifying the valid path to the existing empty directory.
  2. Launch SQL Manager and open the Database Registration Info dialog for the database which you need to add to the SVN. Switch to the Change Management tab and press the Repository Management Wizard button.
  3. Choose the RadioButton Create new repository item and press 'Next'.
  4. Choose the RadioButton Subversion item and press 'Next'.
  5. Specify the path to your Subversion server libraries in the Subversion client libraries path field (for example: "C:\Program Files\CollabNet Subversion Server\"). If you use the client part only (in case of using a remote SVN server) you need to specify the path to your installed client part (for example: "C:\Program Files\CollabNet Subversion Client\"). Check the ability to load the libraries by clicking the 'Test' button and press 'Next'.
  6. Specify the path to your server repository in the Server path field as 'file:///c:/svnrepository/'; specify your working copy directory or any other empty directory where the working copy will be created automatically in the Local path field as 'c:\project\'; specify a name for your database repository in the Repository name field (for example: "mydb"); press 'Next' two times.
  7. Press the 'Run' button to start the process.
  8. After the process has finished, press the 'Close' button and then press the 'Yes' button in the popup dialog asking your to apply the settings.
  9. Press 'OK' to apply the Version Control settings and close the Database Registration Info dialog.


Rollback to previous revision state

If you want to rollback a database to the state of a previous revision then you need to perform the following actions:

  1. Right-click database in the DB Explorer and select Change management | Get Change Script item from the popup menu or select the Tools | Change Management | Get Change Script in the main program menu. Get change script wizard will appear.
  2. On the second step check RadioButton Generate differential script in order to generate a script reflecting difference between two database states.
  3. On the third step specify a date or tag as a script end point so as to define a state to which you want to rollback your database and create a reverse script.
  4. Execution of this script will rollback your database to the necessary point.


View database changes

If you want to view committed database changes you can do it in one of the following ways:

  • Using database history:
  1. Right-click database alias in the DB Explorer and select Change management | History item from the popup menu or select the Tools | Change Management | History in the main program menu.
  2. Define the Period within the corresponding section. Changes made in this period will be displayed in the working area.
  3. At the top of the window you can find a table that displays information about changes made in the specified period. It displays transaction ID, Date when transaction was made, name of the User who made changes and Comment to a transaction if any. In the bottom part of the window you can view SQL statement of the selected action.
  • Using tags and change script:
  1. Right-click database alias in the DB Explorer and select Change management | Get Change Script item from the popup menu or select the Tools | Change Management | Get Change Script in the main program menu. The Get change script wizard will appear.
  2. On the second step check RadioButton Generate differential script in order to generate a script reflecting difference between two database states.
  3. On the third step you may either select tags from the drop-down list to specify two database states to view changes between or pick up dates to define a period of changes.
  4. After that a generated change script will show you the differences between two database states.


View procedure changes

If you have modified a procedure and want to view committed changes then you need to do the following:

  1. Right-click this procedure in the DB Explorer.
  2. Select Change management | History item from the popup menu. You will see a table of object changes history.
  3. Select two procedure revisions you need to compare.
  4. Right-click any of the objects to call the context menu and select the Compare Properties or Compare DDL item to view differences as table of properties or as object script respectively.
  5. If you are comparing properties then in the window appeared you will see a table containing all procedure properties and its value in compared revisions. Properties with different values are highlighted with grey.
  6. If you are comparing DDL then in the window appeared you will see DDL of procedures revisions. Extra lines in an early revision script are red, in latter revision - grey. Lines for pasting missing lines are yellow and different lines are blue.


Create a simple report in report designer

SQL Manager for PostgreSQL
  • Index
  • « Prev
  • Next »

Create simple report in the report designer

To create a report using Report Designer:

  1. Select the Tools | [image] Report Designer main menu item.
  2. In the opened Report Designer select the File | [image] New Report main menu item, or click the [image] New Report item of the navigation bar. The following objects will be added to the newly created report: ReportTitle, MasterData and PageFooter.
  3. Connect to data source.
  4. Add ADOTable or ADOQuery object.
  5. Link ADOTable or ADOQuery with ADODatabase.
  6. Place database fields Page1. Move the required fields from Data Tree to Band MasterData.


Transfer program settings

If you want to apply current program settings (wholly or partially) to SQL Manager for PostgreSQL installed on another machine you can save them into a single *.reg file. This can be done by means of the Save Settings Wizard.

Note that Favorite Queries are not saved in this case. To get access to your queries from another machine please store them in the database.


Update SQL Manager

SQL Manager for PostgreSQL can be updated in the following ways:

  1. Download the SQL Manager for PostgreSQL distribution package from the download page, then extract archive to the preferable directory (e.g. c:\unzipped). Close SQL Manager for PostgreSQL if it's opened and run PgManagerFull.msi or PgManagerLite.msi.
  2. Select the Help | SQL Manager Direct, then press the Update button. If new SQL Manager for PostgreSQL version is released it will be offered for downloading. Click Yes in the dialog window to update SQL Manager for PostgreSQL automatically.


Report bugs and suggestions

Before reporting bugs and suggestions make sure you are using the latest version of the SQL Manager for PostgreSQL. If so then you may contact us via Members Area on https://www.sqlmanager.net/, via Help main menu or by sending an email to support@sqlmanager.net. Please, don't forget to mention your OS version, PostgreSQL server version and program version. Describe the steps to reproduce the bug in detail and illustrate them with screenshots.