Wednesday, 16 August 2017

[Oracle] Oracle Thin JDBC Driver URL Format

1. SID vs Service Name

SID :  DB 인스턴스명 (Unique)
Service Name : 1개 이상의 인스턴스의 별칭. 같은 DB를 다를 용도로 사용할 때, 이를 구별하기 위해도 쓸 수 있다.


2. Thin Driver URL Format

SID (no longer recommended by Oracle to be used):

 jdbc:oracle:thin:[<user>/<password>]@<host>[:<port>]:<SID>

Services:
 jdbc:oracle:thin:[<user>/<password>]@//<host>[:<port>]/<service>

TNSNames:
 jdbc:oracle:thin:[<user>/<password>]@<TNSName>



* ref

https://stackoverflow.com/questions/43866/how-sid-is-different-from-service-name-in-oracle-tnsnames-ora
http://www.orafaq.com/wiki/JDBC

No comments:

Post a Comment