About Oracle URL connection the last ORCL understanding

Source: Internet
Author: User

Today, when the project starts to access a database, it appears
ORA-12505, Tns:listener does not currently know of SID given in Connect Desc.

Look back, my database is configured as:

Driverclassname=oracle.jdbc.driver.oracledriver
url=jdbc:oracle:thin:@158.58.88.102:1521:ESKDB
Username=root
password=aaa111

And then we looked at Oracle's Tnsnames.ora configuration.
eskdb= (DESCRIPTION = (Address_list = (ADDRESS = (PROTOCOL = TCP) (HOST = 158.58.88.102) (PORT = 1521))) (Connect_data = (servic E_name = eskdb)))


According to the truth on the Internet,1, the last ORCL is the database name, my database name is ESKDB, but not
2, the last ORCL is service_name but the configuration of service_name is also eskdb
Finally tangled silent, looking for database DBA help, DBA to help find SID forESKDB1, and the exception hint SID is incorrect, so change the URL to
url=jdbc:oracle:thin:@158.58.88.102:1521:ESKDB1

then restart the project, OK.
Concludes that the last ORCL for database URL connections represents the configured database SID, not the database name or service_name

About Oracle URL connection the last ORCL understanding

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.