7 Replies Latest reply on Jan 29, 2016 4:29 PM by 2715219

    SQLcl 4.2.0.15 (and SQL Dev 4.1.3.20): XMLELEMENT() results in Exception in thread "main" java.lang.UnsatisfiedLinkError: no orageneric11 in java.library.path

    RJLyders

      As always, I am enjoying SQLcl for all of it's new features. Nice job guys...

      A note about an issue I found is shown below...

       

      It appears that any use of XMLELEMENT() in the latest SQLcl 4.2.0.15 results in a Java exception ClassLoader error.

       

      NOTE: SQL Dev 4.1.3.20 doesn't show any error when testing with the exact same SQL, but it returns an empty row of blank XML. This is the case whether you run the SQL using XMLELEMENT() in statement or script mode.

       

      Here is the test SQL to generate XML:

          select XMLElement("Employee",XMLAttributes(1 AS "EmployeeID", 2 AS "ManagerID")) as XML  from dual;

       

      Below are my test results from SQL*Plus and SQLcl...

      ---------------------------------------------------------------------------------------

      D:\Users\richard.lyders\Documents\RJLG#\INC0015337\research>sqlplus foo/bar@dev

       

      SQL*Plus: Release 12.1.0.2.0 Production on Thu Jan 7 14:15:11 2016

       

      Copyright (c) 1982, 2014, Oracle.  All rights reserved.

       

      Connected to:

      Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

      With the Partitioning, OLAP, Data Mining and Real Application Testing options

       

      SQL> select XMLElement("Employee",XMLAttributes(1 AS "EmployeeID", 2 AS "ManagerID")) as XML from dual;

       

      XML

      --------------------------------------------------------------------------------

      <Employee EmployeeID="1" ManagerID="2"></Employee>

       

      SQL> exit

      Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

      With the Partitioning, OLAP, Data Mining and Real Application Testing options

       

      D:\Users\richard.lyders\Documents\RJLG#\INC0015337\research>sql foo/bar@dev

       

      SQLcl: Release 4.2.0.15.295.1605 RC on Thu Jan 07 14:15:32 2016

       

      Copyright (c) 1982, 2016, Oracle.  All rights reserved.

       

      Connected to:

      Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

      With the Partitioning, OLAP, Data Mining and Real Application Testing options

       

      SQL> select XMLElement("Employee",XMLAttributes(1 AS "EmployeeID", 2 AS "ManagerID")) as XML from dual;

       

      Exception in thread "main" java.lang.UnsatisfiedLinkError: no orageneric11 in java.library.path

              at java.lang.ClassLoader.loadLibrary(Unknown Source)

              at java.lang.Runtime.loadLibrary0(Unknown Source)

              at java.lang.System.loadLibrary(Unknown Source)

              at oracle.xdb.XMLType.getConnType(XMLType.java:4234)

              at oracle.xdb.XMLType.initConn(XMLType.java:4175)

              at oracle.xdb.XMLType.<init>(XMLType.java:1514)

              at oracle.xdb.XMLType.createXML(XMLType.java:926)

              at oracle.xdb.XMLType.createXML(XMLType.java:900)

              at oracle.jdbc.driver.NamedTypeAccessor$XMLFactory.createXML(NamedTypeAccessor.java:118)

              at oracle.jdbc.driver.NamedTypeAccessor.getOracleObject(NamedTypeAccessor.java:249)

              at oracle.jdbc.driver.GeneratedStatement.getOracleObject(GeneratedStatement.java:525)

              at oracle.jdbc.driver.GeneratedScrollableResultSet.getOracleObject(GeneratedScrollableResultSet.java:1434)

              at oracle.dbtools.db.SQLPLUSCmdFormatter.rset2sqlplus(SQLPLUSCmdFormatter.java:241)

              at oracle.dbtools.db.ResultSetFormatter.rset2sqlplus(ResultSetFormatter.java:249)

              at oracle.dbtools.db.ResultSetFormatter.rset2sqlplus(ResultSetFormatter.java:223)

              at oracle.dbtools.db.ResultSetFormatter.formatResults(ResultSetFormatter.java:124)

              at oracle.dbtools.db.ResultSetFormatter.formatResults(ResultSetFormatter.java:62)

              at oracle.dbtools.raptor.newscriptrunner.SQL.processResultSet(SQL.java:498)

              at oracle.dbtools.raptor.newscriptrunner.SQL.executeQuery(SQL.java:422)

              at oracle.dbtools.raptor.newscriptrunner.SQL.run(SQL.java:56)

              at oracle.dbtools.raptor.newscriptrunner.ScriptRunner.runSQL(ScriptRunner.java:294)

              at oracle.dbtools.raptor.newscriptrunner.ScriptRunner.run(ScriptRunner.java:202)

              at oracle.dbtools.raptor.newscriptrunner.ScriptExecutor.run(ScriptExecutor.java:286)

              at oracle.dbtools.raptor.newscriptrunner.ScriptExecutor.run(ScriptExecutor.java:191)

              at oracle.dbtools.raptor.scriptrunner.cmdline.SqlCli.process(SqlCli.java:255)

              at oracle.dbtools.raptor.scriptrunner.cmdline.SqlCli.processLine(SqlCli.java:261)

              at oracle.dbtools.raptor.scriptrunner.cmdline.SqlCli.startSQLPlus(SqlCli.java:737)

              at oracle.dbtools.raptor.scriptrunner.cmdline.SqlCli.main(SqlCli.java:307)