Java 和 Hibernate 中的 ArrayIndexOutOfBoundsException

riy*_*ana 1 java hibernate exception indexoutofboundsexception

我正在使用 Hibernate 并得到异常 ArrayIndexOutOfBoundsException。可能的原因是什么?

小智 8

如果您将旧的JDBC驱动程序与Oracle一起使用,则 Hibernate 可能会抛出此异常。在某些时候,JDBC diver 中存在一个带有fetch-size 的错误,这意味着如果您在 Hibernate(hibernate.properties 或 hibernate.cfg.xml)中使用的 fetch-size 与 jdbc 级别中的不同,你有一个ArrayIndexOutOfBoundsException