Table of Contents

Jdbc - URL (and Driver Class)

About

JDBC is using URL to locate the database schema.

Database URLs are strings that you specify for the value of the url property of the DataSource object.

You can add to all JDBC URL, the user and the password in the query part. Example

jdbc:subProtocol://hostname;user=[userName];password=[userPassword];DatabaseName=[Databasename]

The userName and the userPassword must be encoded as all query properties.

URL

The getConnection function gives the following format for the beginning of the string.

jdbc:subprotocol:subname

The format of a url is DB-specific but many follows the following syntax:

jdbc:subprotocol:uri
# ie 
jdbc:subprotocol:scheme://autority....

where:

Default Values

Hyperion

Microsoft SQL Server 2005

Microsoft SQL Server 2000

IBM Db2 Universal Database version 9

IBM Db2 Universal Database version 8

Sybase Adaptive Server Enterprise 15

DB2

Odbc Bridge

see JDBC - ODBC bridge

Oracle

Oracle Maven Repository

Oracle 11g

The colon “:” implies SID, the slash “/” implies service_name.

Example:

jdbc:oracle:thin:scott/tiger@myhost:1521:mysid

Oracle 10g

Oracle 9i

Oracle BI Server (OBIEE)

With user: jdbc:oraclebi://localhost:9703/user=Nico;password=********;

Others parameters:

SQL Server

2008 R2

Example:

jdbc:sqlserver://localhost;user=MyUserName;password=*****;databaseName=AdventureWorks;

Sybase IQ 12

Informix IDS 10.0

Informix IDS 9.4

Teradata

NCR Teradata 12.0

NCR Teradata V2R6.2

NCR Teradata V2R5.1

MySQL

MySQL 5.0

MySQL 4.1

Netezza 4.0

TimesTen

The driver= com.timesten.jdbc.TimesTenDriver. The jar driver is located int the TIMESTEN_BASE\lib directory. The jar file ttjdbc5.jar is for the Java SDK version 5 and ttjdbc6.jar is for version 6. (ttjdbc5.jar, ttjdbc6.jar)

URL:

jdbc:timesten:{direct|client}:dsn=DSNname;[DSNattributes;]

Example:

jdbc:timesten:client:dsn=TT_DATA_STORE;UID=login;Pwd=pwd;SQLQUERYTIMEOUT=0

RPAS 13.0.1 int1

Java DB - Derby

Embedded

For the Embedded configuration

Client/server

For the client/server communication:

Documentation / Reference