java.sql.SQLException: Io exception: Got minus one from a read call during JDBC connection with oracle

后端 未结 7 1168
故里飘歌
故里飘歌 2020-12-19 07:52

Hi I am new to java when I tried to connect oracle with my java sample code I got the above exception

My Code is

import java.sql.*;
import java.io.IO         


        
7条回答
  •  感情败类
    2020-12-19 08:36

    I know this thread is a bit old, but here is what worked for me.

    check the connection using a oracle db client like sql developer or something else to make sure the connection string is working and able to connect to the db with it. If you are using Oracle db Express Edition which is XE, SID is XE and port is 1521 no matter where the web client is running. you can also check this from the web client settings and other places.

提交回复
热议问题