java.sql.SQLException: ORA-01005: null password given; logon denied at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:628) at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:557) at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:552) at oracle.jdbc.driver.T4CTTIfun.processError(T4CTTIfun.java:1312) at oracle.jdbc.driver.T4CTTIoauthenticate.processError(T4CTTIoauthenticate.java:699) at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:726) at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:291) at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:389) at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTHWithO5Logon(T4CTTIoauthenticate.java:1455) at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:1219) at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:1173) at oracle.jdbc.driver.T4CConnection.authenticateUserForLogon(T4CConnection.java:1030) at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:646) at oracle.jdbc.driver.PhysicalConnection.connect(PhysicalConnection.java:1032) at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:90) at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:681) at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:602) at java.sql.DriverManager.getConnection(DriverManager.java:664) at java.sql.DriverManager.getConnection(DriverManager.java:247) at com.adtec.moia.control.agent.util.MoiaUtil.getConnection(MoiaUtil.java:195) at com.adtec.moia.control.agent.deal.dbsjob.DbsJobExecutor.execute(DbsJobExecutor.java:70) at com.adtec.moia.control.agent.deal.JobExecuteThread.run(JobExecuteThread.java:99) at java.lang.Thread.run(Thread.java:748) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)
Hello! I'm getting this exceptionwhile trying to establish a JDBC connection to an Oracle database (10g Express Edition): java.sql.SQLException: ORA-01005: null password given; logon denied The code is the following:try { OracleDataSource ods = newOracleDataSource(); ods.setDriverType("thin"); ods.setPassword("rafael"); ods.setUser("rafael"); ods.setDatabaseName("XE"); ods.setPortNumber(1521); ods.setServerName("iceman"); Connection c = ods.getConnection(); } catch (SQLException e) { e.printStackTrace(); }I'm also getting the same exceptionwhile running this code:Connection c = DriverManager.getConnection("jdbc:oracle:thin:#iceman:1521:XE", "rafael", "rafael");An interesting fact is DbVisualizer is successfully connecting to this database using exactly the above url. You can see the screen captured here: http://db.tt/YKxQCvf Anyone can help me to bypass this problem? Thanks in advance Edited by: user13275297 on 22/06/2011 13:14
1 2 3 4
This could be the jar issue, postthe jdk versionand jar you are usingto establish the db connection. if you are notusing ojdbc14.jar, then you can make atrywith this jar. also go through the below post, it might help you: Login failure using Oracle Express 10.2, Java 6and ojdbc5/611.x