0 Replies Latest reply on Dec 17, 2015 11:06 AM by berx

    sqlcl 4.2.0.15.349.0706 throws java stack at "script xxx" if file xxx does not exist (Win7_64)

    berx

      I'm trying sqlcl 4.2.0.15.349.0706 on Windows 7 - 64 bit.

       

      the script "js" does not exist:

       

      D:\Programs\sqlcl.4.2.0.15.349.0706\bin>sql.bat /nolog
      SQLcl: Release 4.2.0.15.349.0706 RC on Thu Dec 17 11:47:37 2015
      Copyright (c) 1982, 2015, Oracle.  All rights reserved.
      
      SQL> script js
      javax.script.ScriptException: <eval>:1:32 Missing close quote
      out.write('Could not read script
                                      ^ in <eval> at line number 1 at column number 32
              at jdk.nashorn.api.scripting.NashornScriptEngine.throwAsScriptException(NashornScriptEngine.java:455)
              at jdk.nashorn.api.scripting.NashornScriptEngine.compileImpl(NashornScriptEngine.java:522)
              at jdk.nashorn.api.scripting.NashornScriptEngine.compileImpl(NashornScriptEngine.java:509)
              at jdk.nashorn.api.scripting.NashornScriptEngine.evalImpl(NashornScriptEngine.java:397)
              at jdk.nashorn.api.scripting.NashornScriptEngine.eval(NashornScriptEngine.java:152)
              at javax.script.AbstractScriptEngine.eval(Unknown Source)
              at oracle.dbtools.scripting.ScriptingUtils.runScript(ScriptingUtils.java:22)
              at oracle.dbtools.raptor.scriptrunner.commands.ScriptCommand.runScript(ScriptCommand.java:154)
              at oracle.dbtools.raptor.scriptrunner.commands.ScriptCommand.handleEvent(ScriptCommand.java:124)
              at oracle.dbtools.raptor.newscriptrunner.CommandRegistry.fireListeners(CommandRegistry.java:373)
              at oracle.dbtools.raptor.newscriptrunner.ScriptRunner.run(ScriptRunner.java:197)
              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:277)
              at oracle.dbtools.raptor.scriptrunner.cmdline.SqlCli.processLine(SqlCli.java:284)
              at oracle.dbtools.raptor.scriptrunner.cmdline.SqlCli.startSQLPlus(SqlCli.java:760)
              at oracle.dbtools.raptor.scriptrunner.cmdline.SqlCli.main(SqlCli.java:330)
      Caused by: jdk.nashorn.internal.runtime.ParserException: <eval>:1:32 Missing close quote
      out.write('Could not read script
                                      ^
              at jdk.nashorn.internal.parser.Lexer.error(Lexer.java:1714)
              at jdk.nashorn.internal.parser.Lexer.scanString(Lexer.java:1009)
              at jdk.nashorn.internal.parser.Lexer.lexify(Lexer.java:1623)
              at jdk.nashorn.internal.parser.AbstractParser.getToken(AbstractParser.java:132)
              at jdk.nashorn.internal.parser.AbstractParser.nextToken(AbstractParser.java:211)
              at jdk.nashorn.internal.parser.AbstractParser.nextOrEOL(AbstractParser.java:170)
              at jdk.nashorn.internal.parser.AbstractParser.next(AbstractParser.java:157)
              at jdk.nashorn.internal.parser.Parser.parse(Parser.java:282)
              at jdk.nashorn.internal.parser.Parser.parse(Parser.java:250)
              at jdk.nashorn.internal.runtime.Context.compile(Context.java:1207)
              at jdk.nashorn.internal.runtime.Context.compileScript(Context.java:1179)
              at jdk.nashorn.internal.runtime.Context.compileScript(Context.java:594)
              at jdk.nashorn.api.scripting.NashornScriptEngine.compileImpl(NashornScriptEngine.java:520)
              ... 15 more
      Could not load file: js.js
      

       

      it's not an issue for me, just to Report it.

      I tested with a DB-Connection (no /nolog) - same result

       

      Martin