DriverManager.getConnection() Method--Establish JDBC Driver Connection
A JDBC Driver connection can be established using a DriverManager.getConnection() method with a URL in the following format:
jdbc:ingres://host:port{,port}{;host:port{,port}}/db{;attr=value}
where:
host
Specifies the network name or address of the host on which the target Data Access Server (DAS) is running. TCP/IPv6 addresses (colon-hexadecimal format) must be enclosed in square brackets, for example: [::1]. Multiple hosts with associated ports must be separated by semi-colons.
port
Specifies the network port used by the DAS. This can be a numeric port number or a symbolic port address such as II7 (the Ingres default) or VW7 (the Vector default), which is the instance ID followed by the number 7.
Multiple ports can be specified, one for each configured DAS. For example, if DAS is configured with a startup count of 4 and a listen port of II7+:
II7,II8,II9,II10
The driver attempts to connect to each host/port combination until a successful connection is made. The connection request between the JDBC application and the DAS fails only if all port attempts fail. If a successful connection to DAS is made, but the subsequent connection between DAS and the DBMS fails, then the connection request fails immediately and subsequent ports are not tried.
db
Specifies the target database. Any valid Ingres or Vector database designation can be used including vnode and server class (that is, vnode::dbname/server_class).
attr=value
(Optional) Specifies the attribute name and value pair. Multiple attribute pairs are separated by a semi-colon.
Attributes represent driver properties that are implementation-specific and can be used to configure the new connection. For details, see
JDBC Driver Properties.
Note: A user ID and password are required when making remote connections. They can be included as parameters to the getConnection() method as driver properties or as URL attributes.