JDBC connection string

JDBC Connect string (thin)

"jdbc:oracle:thin:@[host]:[port]:[database_service]"

replace :

  • [service] name of the service you wish to connect to. eg oneview
  • [port] with the port number that the required service is running upon eg 1521
  • [host] with the host name listening on that the port eg advt-db-lat

eg

"jdbc:oracle:thin:@l"jdbc:oracle:thin:@advt-db-lat:1521:oneview"

JDBC Connect string with RAC failover

  • To enable node failover and load-balance, replace [host] with the the tnsnames string (ignore the tns alias) :
//jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=xxx)
(PORT=1234)) (ADDRESS=(PROTOCOL=TCP)(HOST=xxxx)(PORT=1234))
(LOAD_BALANCE = YES)(FAILOVER=ON) (CONNECT_DATA=(SERVER=SHARED)(SERVICE_NAME=
xxxx)))//