This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Oracle JDBC driver & dbURL  RSS feed

 
Ma Di
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I use Oracle in UNIX environment. I know the information of
dbhost, port and service-name.
However I can't use the form of "jdbc racle:thin:@dbhost ort:sid"
because I don't have a "sid". Can you tell me how to connect DB
in such a situation?
By the way, could there anyone tell me where to find the format of dbURl passed to DriverManager.getConnection(dbURL) as I saw
different DB use different dbURL format.
Thanks a lot.
Rgds,
Ma Di
 
ram menon
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Every Oracle installation will have an SID. By default it is ORCL. But you can change this during installation.
You can use the OCI driver if you do not know the SID.
jdbcracleci8:@<database>
where <database> is either an entry in tnsnames.ora or a SQL*net
name-value pair.
Hope this helps,
Ram
 
Ma Di
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks a lot. Ram.
Rgds,
Ma Di
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!