Tool Properties

DbVisualizer Logo
DbVisualizer 4.0.3 (Free and Personal editions)
January 2004
http://www.dbvis.com
support@dbvis.com


[ Master documentation index ]

Customizing DbVisualizer

DbVisualizer is highly customizable with more than 50 different properties. You can control formatting, layout and the way DbVisualizer interacts with databases. The default settings are good enough for the average user but sometimes it is necessary to modify a property or two. This chapter guides you through all the properties.


Figure: The Tool Properties window

The Tool Properties window is organized as in many other applications. The category list in the left area and the properties for the selected category in the right area. A category may group one or several properties.

The buttons at the bottom of the window control whether the changed properties should be applied using the Ok button, if changes should be reverted using the Cancel button or if the factory defaults should be applied using the Defaults button.

Note that the Ok and Defaults buttons are used to apply values for all categories and not only the currently selected one.

The user preferences (XML) file

All properties are saved in an XML file. The exact location of this file is listed in the frame header of the main window. The XML file contains, in addition to all properties, also the information about drivers, database connections, bookmarks, etc. The general recommendation is to not edit this file manually even though it is quite easy to do so.

DbVisualizer automatically creates a backup copy of the XML file when the application is started. The location of this file is the same as for the standard XML file except that the .bak suffix is appended to the file name. The standard XML file might get broken for various reasons. If a warning message that the XML file could not be read is displayed during launch of DbVisualizer then simply copy the backup file to the standard location and restart the application. If the XML file is moved from its standard location or if it is removed then DbVisualizer will automatically create a new one.

Tip: the -up command line argument is used to identify the file name (and path) to an alternate XML file.

Categories

The following sections describes each property.

Appearance

Property
Description
Look and Feel
Controls which look and feel will be used. The default look and feel is Alloy for all platforms except Mac OS X. You must restart DbVisualizer in order to use a new look and feel.

Metal


CDE/Motif


Windows

(This look and feel can only be used on Windows)

Kunststoff


Alloy (default)


Mac OS X (default on Mac OS X)

(This look and feel is only available on
Mac OS X platforms)


Icon Collection
You can choose from three different icon collections. You must restart DbVisualizer in order to see a new icon collection.
IconExperience.com (default)


Java Graphics



Dean S. Jones


Show Tab Icons Specifies whether an icon will appear in the header of all tabs.

Database Connection

Property
Description
Run "Connect All" at Startup Defines whether a database connection will be connected when the Connect All operation is selected in the main window menu bar.
Save Passwords Enable to saving database connections passwords in the XML file.  (Passwords are encrypted).
Connection Timeout Specify number of seconds that the driver will wait until terminating ongoing connection request.
Note: This property is handled by JDBC drivers and might not be supported.
Show only default Database or Schema Check to enable that only default database and/or schemas will appear in the Database Objects tree and throughout the application. The default Schema in Oracle is the schema with the same name as the userid that is used when connecting.
Confirm "Disconnect All"
Checking this property will force a dialog to be displayed before disconnecting all current database connections using the Disconnect All operation.

Data Formats

Property
Description
Date Format
Select the date format that will be used throughout the application (i.e grids, forms and during editing).
Time Format
Select the time format that will be used throughout the application (i.e grids, forms and during editing).
Format Numbers
Specifies whether numbers will be formatted to include thousand separators. The separator character is determined based on the current locale setting.
Null String
This is the string representation of the null value. This string is the readable form of null and appears in grids, forms, exports and during editing.
BLOB
Specifies how BLOB and binary data values will be represented in grids. Setting this property to By Value will result in performance penalties and the memory consumption will increase dramatically.
CLOB
Specifies how BLOB and binary data values will be represented in grids. Setting this property to By Value will result in performance penalties and the memory consumption will increase dramatically.

Table Data

Property
Description
Show Table Row Count
Specifies if the number of rows in a table will be displayed in the header of the table when in the Database Objects->Data tab. Enabling this property will cause an extra round trip to the database (i.e minor performance penalty)
Highlight Primary Key Columns
Specifies if Primary Key columns will be indicated in the Database Objects->Data tab, Variable Substitution dialog, SQL Commander Result grids and in the References Graph.
Confirm Data Deletion*
Check to enable the Confirm Delete dialog when removing rows in the Inline and Form based editors
Include Variables in SQL
Specifies if the right click menu operations in the Data tab will create appropriate SQL statements that include DbVisualizer variables or if the generated statements are plain SQL. Letting DbVisualizer generating statements with variables results in the variable substitution dialog being displayed when these statements are executed in the SQL Commander.

Database Objects

The database objects category is used to control what columns will be displayed in the various tabs for the selected objects in the Database Objects tree. The sub categories control the appropriate tabs for the following object types:

Database Connections:


Tables and Views:


SQL

DbVisualizer relies heavily on the JDBC driver specification and the pre-defined features that are used to explore databases. DbVisualizer adds a number of features that are not pre-defined in JDBC. These features are accomplished by standard SQL calls that are composed implicitly by DbVisualizer. The SQL category groups properties that are related to execution of SQL statements and the processing associated with it.

SQL Statements

This category controls the SQL templates that DbVisualizer uses internally throughout the application. Each SQL template is composed of the standard SQL and the DbVisualizer Variable notation. A variable is identified by the Variable Identifier and can be composed of several parts each delimited by the Variable Delimiter. DbVisualizer relies on a list of pre-defined variable names that are accessed in the SQL Statement Template right click menu:


Figure: All pre-defined variables

A specific pre-defined variable can be used in on or more of the SQL templates. Using a variable in a SQL statement that is not valid will result in the variable appearing as is once the statement is executed.

There is normally no reason to modify the SQL templates nor the variable identifier or delimiter settings. There might however be circumstances when edits are needed:
Note: change of SQL templates should be considered in the Connection Properties tab instead of in Tool Properties. The reason is that SQL templates and the associated settings are most often related to a specific database connection.

Detailed information about variables and their syntax is provided in the Executing SQL statements in the SQL Commander.

Property
Name
Description
SQL Templates
select *
Command used when selecting all rows for a table
select * where
Command used when selecting some rows for a table
select count(*)
Command used to get the number of rows in a table
insert into
Command used to insert a new row into a table
update where
Command used to update an existing row in a table
delete where
Command used to delete a specific row in a table
drop table
Command used to drop a specific table
Monitor Row Count
Command used to get the number of rows in a table and the current time stamp
Monitor Row Count Change
Command used to get the row count difference in a table compared to the previous execution. The calculated row count and the current time stamp is returned
create table
Command used to create a new table with an  optional primary key
create index
Command used to create an index for a specific table
Variable Identifier

The identifier for a variable. A variable starts and ends with this identifier.
Variable Delimiter

The delimiter used to identify the parts of a variable.

Statement Delimiters

Statement delimiters define how a script should be divided into specific SQL statements in the pre-processing phase.

Property
Description
SQL Statement Delimiter 1
Defines the character(s) used to delimit one SQL statement from another in a SQL script
SQL Statement Delimiter 2
Defines the additional character(s) used to delimit one SQL statement from another in a SQL script. If there is no need for more then one SQL statement delimiter then set this one to the same as delimiter 1.
Allow "go" as Delimiter
Specifies whether go as the first word on a single line will be interpreted as a statement delimiter.
Begin Identifier
Defines the character(s) that identifies the start of an anonymous SQL block
End Identifier
Defines the character(s) that identifies the end of an anonymous SQL block

Pre-processing

Pre-processing properties define as the name implies the settings that are used when DbVisualizer pre-processes any SQL statement or script of statements before executing it with the JDBC driver.
Comments
Property
Description
Single Line Identifier 1
Defines the character(s) that identifies the beginning of a one line comment
Single Line Identifier 2
Defines the additional character(s) that identifies the beginning of a one line comment
Block Comment Begin Identifier
Specifies the character(s) that identifies the start of a multi line comment block
End
Specifies the character(s) that identifies the end of a multi line comment block
New Lines
Property
Description
Remove New Line Characters
Formatting an SQL statement manually by adding new lines is quite useful to make it more readable. Some JDBC drivers (or databases) do not like new line controls in a statement and simply fail with a more or less cryptic error message. This property specifies if new line control characters will be removed from a statement just before it is executed by the JDBC driver.

Note: It is strongly recommended to enable this property if using the db2jcc driver for DB2.

Transaction

Property
Description
Auto Commit
Defines if each executed SQL statement will be auto committed or not. This setting applies for all SQL's that are executed in the SQL Commander. The inline and form editors in DbVisualizer Personal handles the commit and rollback management independently of the setting of Auto Commit.
Pending Transactions at Disconnect
Defines what DbVisualizer will do on exit from the application when the auto commit setting is disabled.
Transaction Isolation
Attempts to change the transaction isolation level for all database connections. Note: If this property is changed during a transaction, the result is JDBC driver specific.

Copy

The copy category groups properties that are used to control the result of using Copy Selected Cells or when using the Ctrl-C shortcut in grids.

Property
Description
Column Delimiter
Specifies the delimiter between columns in a multi column copy
End of Line Delimiter
Specifies the new line control characters for multi row copy requests
Include Column Headers
Check to enable that column header labels are copied too

Bookmarks

Property
Description
Number of Bookmarks Limit
Specifies the number of SQL bookmarks that the New and History bookmark object may keep until the lists are truncated.

Grid

Property
Description
Fit Grid Column Widths
Enable to let DbVisualizer automatically fit the content in each grid column based on the widest cell value.
Meaning of setting Max Chars
The Max Chars property in the Database Objects Data tab and in the SQL Commander is used to control the max number of  characters that text values can hold. If the number of characters for a text column is wider then this setting then the column is colored in a light red color.

The meaning of setting this property can be one of the following:
  • Truncate Values
    Will truncate the original value to be less then the setting of Max Chars.
    Note: this will affect any subsequent edits and SQL operations that use the value since it's truncated. This setting is only useful to save memory if viewing very large text columns.
  • Truncate Values Visually
    Will truncate the visible value only and leave the original value intact. This is the preferred setting since it will not harm the original value. The disadvantage is that more memory is needed if dealing with large text columns.

Editor

The editor category is used to modify the short cut settings that are used in the SQL editors.

Fonts

Individual fonts can be defined for SQL editors and grids.

Debug

The debug category is used to control the amount of output that is produced when setting various debug modes. Normally only error messages are displayed in the default debug destination which is the View->Debug Window. The support team at Minq Software often refer to the debug properties when we want more information in a problem situation.

Property
Description
Debug Output Destination
Specifies the destination to which all debug messages will be written to. It is not advisable to set this to Off since then also error messages will then also be ignored. Standard Out is only useful if the debug mode of the DbVisualizer launcher is enabled.
Debug DbVisualizer
Defines the amount of logging that will be produced. Full output is when Log Level is set to Debug and lowest output is Error. Setting Detail Level to Full produces the most detail and also consume more resources.

Read more about Problem Resolution.


Copyright © 2004 Minq Software AB. All rights reserved.