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!
Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.
Possible solutions may depend on whether you are using a JDBC thin or thick (oci) connection. If the ORACLE_HOME environment variable is set, then SQLcl wants to use a thick connection. Unless the same 'sealing violation' makes them fail, running 'show connection' or 'show jdbc' from SQLcl will show which type of connection is in use (java:oracle:thin or java:oracle:oci8).
The error complaining about libocijdbc11.so probably indicates use of a thick connection. So if that is the source of the 'sealing violation' [except I think such a violation means some .class files from a sealed package are getting loaded from two different locations (directories or jar files) rather than the .so or .dll files], then not setting ORACLE_HOME may fix the issue. But if a thick connection is required, then make sure only a single instance of the jar file containing the package oracle.jdbc.internal is accessible to SQLcl, via the PATH variable, I assume. Corrections welcome (as I have never seen this issue before!)
Thanks very much for the reply, you're right.
I verified that if I unset ORACLE_HOME then 'show connection' and 'show jdbc' both indicate a thin client and the query works.
SQL> select 1 from dual ;
1
----------
SQL> show connection
CONNECTION: xxxxxx@jdbc:oracle:thin:@farina.jgi-psf.org:1521:xzxxxx
CONNECTION_IDENTIFIER: farina.jgi-psf.org:1521:xxxxxx
CONNECTION_DB_VERSION: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
NOLOG: false
PRELIMAUTH: false
SQL> show jdbc
-- Database Info --
Database Product Name: Oracle
Database Product Version: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
Database Major Version: 11
Database Minor Version: 2
-- Driver Info --
Driver Name: Oracle JDBC driver
Driver Version: 12.2.0.1.0
Driver Major Version: 12
Driver Minor Version: 2
Driver URL: jdbc:oracle:thin:@farina.jgi-psf.org:1521:xxxxxx
Driver Location:
resource: oracle/jdbc/OracleDriver.class
jar: /global/projectb/scratch/copeland/software/Packages/Util/sqlcl/lib/ojdbc8.jar
JarSize: 4036257
JarDate: Thu Feb 08 20:30:44 GMT 2018
resourceSize: 2604
resourceDate: Tue Dec 13 08:39:48 GMT 2016