As I would like to do query via JPA, I got this error message
IO Error: Size Data Unit (SDU) mismatch:oracle.net.ns.NetException: Size Data Unit (SDU) mismatch
Solution
This problem results from inappropriate JDBC jar file, just upgrade your JDBC jar file to 11.2.0.3.0 or above
1 comment:
Thank you for the tip!
Small completion:
If the problem is in your application, then it is presumably easy to change the JDBC driver jar file.
Otherwise, if it manifests in a SQL IDE like Oracle SQL Developer, which has built-in drivers for Oracle (and offers the possibility to change the drivers only for other few 3rd party DB engines), the steps would be like the ones described bellow.
You should replace the JDBC driver with a version > 11.2.0.3, as indicated in the original post.
Thus, download:
- ojdbc5.jar for java 5 or
- ojdbc6.jar for java 6
from the Oracle JDBC drivers page (e.g. http://www.oracle.com/technetwork/database/enterprise-edition/jdbc-112010-090769.html).
In the case of Oracle SQL Developer (3.1.x):
- close the IDE (to avoid a lock on that jar file);
- replace the jar containing the driver from
${ora_sqldev_home}/jdbc/lib/ojdbc6.jar with the downloaded jar (the version for the java 6, in the case of Oracle SQL Developer 3.1!);
- restart the IDE and it should work.
Notice: by ${ora_sqldev_home} we denoted the directory where the kit of the Oracle SQL Dev. 3.1 was installed/unarchived.
Post a Comment