Tuesday 23 June 2015

Unable to solve the JDBC error - java.lang.ArrayIndexOutOfBoundsException: 4 at oracle.jdbc.driver.T4C8TTIdty


I was facing the below error while creating a stand alone JDBC connection.

java.lang.ArrayIndexOutOfBoundsException: 4
        at oracle.jdbc.driver.T4C8TTIdty.<init>(T4C8TTIdty.java:480)
        at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1161)
        at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:320)
        at oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:547)
        at oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:236)
        at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
        at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:521)
        at java.sql.DriverManager.getConnection(DriverManager.java:582)
        at java.sql.DriverManager.getConnection(DriverManager.java:185)
   


This was becasue the Target database was on oracle 8i. so we had to add the 8i compatible jar - classes_12g.jar to the pre-class path which resolved the issue.

No comments:

Post a Comment