Skip to Main Content

Java Database Connectivity (JDBC)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Oracle 19c jdbc driver doesn't support schema names bigger than 30 bytes

User_K11SUJun 23 2021

According to Oracle's 19cĀ documentation:
The schema name can be 128 bytes, the table name can be 128 bytes, and the column name can be 128 bytes.
However, I'm facing this issue whenever I try to use a schema name bigger than 30 bytes:

Caused by: java.sql.SQLException: Invalid argument(s) in call
at oracle.jdbc.driver.PhysicalConnection.setSchema(PhysicalConnection.java:9462)
at com.zaxxer.hikari.pool.ProxyConnection.setSchema(ProxyConnection.java:460)
at com.zaxxer.hikari.pool.HikariProxyConnection.setSchema(HikariProxyConnection.java)

The driver used is:

        <dependency>
            <groupId>com.oracle.database.jdbc</groupId>
            <artifactId>ojdbc8</artifactId>
            <version>19.7.0.0</version>
        </dependency>

It looks like the driver is not supporting longer object names introduced as per 12c version, any clues if this is somehow configurable? Could it also perhaps be some AWS RDS specific issue?
On SQL Developer using same jdbc url:

SELECT name, value FROM v$parameter WHERE name = 'compatible';

NAME       | VALUE
-------------------
compatible | 19.0.0

ALTER SESSION SET CURRENT_SCHEMA = VERY_VERY_VERY_LONG_SCHEMA_NAME;

Session altered.
Comments
Post Details
Added on Jun 23 2021
5 comments
1,795 views