You can use the pages in the New Connection wizard to create
a connection profile, so that you can connect to and browse existing
data object. This topic explains how to open the New Connection wizard
from the Data Source Explorer view (or
the Administration Explorer for products that include this view).
The New Connection wizard pages can also be embedded in other wizards
in the workbench.
About this task
You can also create a new connection by creating a duplicate
of an existing connection. This method is useful if you want to create
a connection that is similar to an existing connection but with different
properties. To create a duplicate of an existing connection, right-click
a connection and select Duplicate. You can
then edit the properties of
the duplicate connection as needed.
Procedure
To connect to a database by using a wizard:
- Right-click in the Data Source Explorer, and select New
Connection from the pop-up menu.
For
products that contain the Administration Explorer, you can also click from the Administration Explorer toolbar.
- On the first page of the wizard, select a database manager,
a JDBC driver, and then specify the connection details.
Note: Your
password is temporarily stored in your workbench while you are connected
to a database server and is removed when you disconnect. To permanently
store your password in the workbench, select Save password.
- Connection identification
- Specify preferences for naming the new connection.
- Use default naming convention
- Specifies that a connection name is generated based on the name
of the database that you are connecting to. This connection name is
displayed in the Data Source Explorer (or
the Administration Explorer for products that contain this view) after
you create the connection.
- Connection name
- Type a name for the connection. Available only if Use default
naming convention is not checked.
- JDBC driver
Specify a JDBC driver to use to connect to the database. JDBC
drivers that appear in the list are fully supported. If a driver that
you want to use is not listed but it is supported by the database
manager, select Other Driver Default and provide
the details.
Click Edit JAR List to open
a window so that you can modify the path to the JAR files that are
being used for a particular JDBC driver. You can also use this window
to view the names and typical locations for JDBC JAR files for each
listed driver.
Global driver properties are set in the Preferences
window, on the Driver
Definitions page.
The IBM® Data
Server Driver for JDBC and SQLJ is included with the workbench product,
and by default the wizard uses the included version of the driver.
It is recommended that you use this version, because it has been tested
thoroughly. If you want to use a different version of this driver,
you can modify the path to the required JAR files by clicking Edit
JAR List. Other JDBC drivers for IBM data servers might also be included, depending
on the workbench product that you are using.
JDBC driver
limitation: Some drivers require a pass code or license file.
Although license information can be set or available in the current
environment, the information might not be available in other environments,
such as on a Web server. The driver does not work if the pass code
or license is not available.
- Connection URL details - Driver Options
- Database
- Specify a name for the database server. This field is not required
for some database servers.
- Location
- For DB2® for z/OS® connections only: Type the DB2 location name that is defined
during installation. You must enter the name in upper case. To determine
the location, host, and port that should be used for DB2 for z/OS connections,
a DB2 for z/OS system programmer or DBA can issue a <cmd
prefix="">DIS DDF where <cmd prefix=""> is
a preassigned character in your system for a particular DB2 subsystem.
- SID
- For Oracle connections only: Specify the Oracle database
system identifier.
- Database location
- For Derby connections only: Type the absolute directory
path to where Derby data is stored on your file system.
To create
a new Derby database, use one of the following options:
- If you are connecting by using the Database Connection page, append ;create=true to
the path that you specified.
- If you are by using the New Database Connection wizard, select Create
the database if required.
- Create the database if required
- For Derby connections only: Select to create the database
in the directory that you specified if the database does not exist.
- Host
- Specify the TCP/IP host name or TCP/IP address of the database
server. This field is not required for some database managers.
- Port number
- Specify the TCP/IP connection port for the selected database on
the host. This field is not required for some database managers.
- Use client authentication
- For DB2 for Linux, UNIX,
and Windows connections
only: Specifies that the operating system performs authentication
on the database partition where the application is invoked. This option
works only if the DB2 instance
that you are connecting to has been configured to support client authentication.
With client authentication, the user ID and password that are specified
during a connection or attachment attempt are compared with the valid
user ID and password combinations on the client node to determine
if the user ID is permitted access to the instance. No further authentication
takes place on the database server. This is sometimes called single
sign-on.
- Use integrated authentication
- For SQL Server connections with specific JDBC drivers only: Specifies
that your access to the SQL Server database is authenticated by the Windows operating system (Windows Integrated Authentication).
A database user name and password are not required. This is also referred
to as "Windows Integrated
Security."
This option is available only if you select one of the
following JDBC drivers:
- SQL Server 2000 - Microsoft SQL
Server 2005 JDBC Driver Default (for SQL Server 2000 Service Pack
4 only)
- SQL Server 2005 - Microsoft SQL
Server 2005 JDBC Driver Default
- SQL Server 2005 - Microsoft SQL
Server 2005 JDBC Driver with system tables filter Default
- User name and Password
- Specify a user name and password with privileges to connect to
the database server.
Note: Your password is temporarily stored in your
workbench while you are connected to a database server and is removed
when you disconnect. To permanently store your password in the workbench,
select Save password.
- Default schema
- Type the name of the schema to use for unqualified database object
references in SQL statements. If you want SQL statements to refer
to database objects that are in other schemas, you must qualify the
names of the objects with the names of their corresponding schemas.
For Informix® databases, this field
is called Default owner.
- Connection URL
- Shows the generated JDBC URL for the JDBC driver that you are
using. The URL identifies the database so that the driver can establish
a connection. The URL format depends on the driver.
For some data sources, you can select filtering
options that can improve connection performance and simplify the Data
Source Explorer view display.{-COMMENT-}I don't see Filter out system tables anymore in RAD 7.5?{-ECOMMENT-}
- Filter out system tables
- For Sybase or SQL Server connections only: Select to filter
system tables out of the connection.
- Catalog
- For Oracle connections only: Select which database catalog
you want to load. You can select User, DBA, or All.
- Retrieve objects created by this user only
- For DB2 for z/OS connections only: Select to load objects
that were created by the user who is specified in the User
ID field.
- Connection URL details - Tracing (not available in some products
or for some database servers)
- The controls on this page enable JDBC tracing for this connection.
JDBC tracing is useful for troubleshooting, but enabling JDBC tracing
can cause performance problems. Therefore, you should only enable
tracing if you are experiencing problems.
- Disable tracing
- Clear this check box to enable JDBC tracing for this connection.
- Directory
- Specify a directory to which the trace files are saved.
- File name
- Specify a base file name for the trace files. More than one trace
file might be created for each connection. If more than one trace
file is generated, this name is used and is appended with an underscore
and numeric values. For example, if you specify trace,
the generated files might be trace_1, trace_2,
and so on.
- Append
- Specifies that trace files are not overwritten if the files already
exist. If this option is selected, new trace information is appended
to any existing trace files.
- Trace levels
- Defines what kind of information is traced. Select a check box
next to each option to include information in the trace file.
- Connection URL details - Optional (not available for some database
servers)
- Specify additional connection properties, for example: readOnly
= true. The properties that you can specify are different
for every JDBC driver. Refer to the JDBC driver documentation for
more examples.
- Optional: On the Filter page,
specify filtering options.
For best performance, you
should use filters when you are connecting to a large database.
If
you do not specify filtering options in the wizard, you can modify
them later by modifying connection properties or by specifying data object filter options. To modify
connection properties, right-click a connection and select Properties.
Filtering
is not enabled by default on the wizard page. To filter your connection,
clear the Disable filter check box, then specify
filtering options either by using an expression or by selecting specific
objects to include or not include in the connection view.
- Complete all other wizard steps and click Finish.
Results
The connection is displayed in the Data Source Explorer
(and
the Administration Explorer for products that contain this view).