Code Monkey home page Code Monkey logo

Comments (6)

RQWangXiaoJun avatar RQWangXiaoJun commented on July 21, 2024

请问方便发一下调用堆栈吗?
jar包里的文件只能读成InputStream,应该调用LocalFile.getInputStream取输入流

from esproc.

FengMingJian avatar FengMingJian commented on July 21, 2024

raqsoftConfig.xml 配置文件内容如下:

<?xml version="1.0" encoding="UTF-8"?>
<Config Version="3">
    <Runtime>
        <DBList>
        </DBList>
        <Esproc>
            <charSet>UTF-8</charSet>
            <splPathList>
                <splPath></splPath>
            </splPathList>
            <dateFormat>yyyy-MM-dd</dateFormat>
            <timeFormat>HH:mm:ss</timeFormat>
            <dateTimeFormat>yyyy-MM-dd HH:mm:ss</dateTimeFormat>
            <mainPath></mainPath>
            <tempPath></tempPath>
            <bufSize>65536</bufSize>
            <localHost/>
            <localPort>0</localPort>
            <parallelNum/>
            <cursorParallelNum/>
            <blockSize/>
            <nullStrings>nan,null,n/a</nullStrings>
            <fetchCount/>
            <extLibsPath/>
        </Esproc>
        <Logger>
            <Level>OFF</Level>
        </Logger>
    </Runtime>
    <JDBC>
    </JDBC>
</Config>

项目结构如下:

src
|---main
     |---java
     |---resources
          |---raqsoftConfig.xml
          |---STUDENT_SCORE_LIST.splx

Java 调用 代码如下:

Connection con = null;
java.sql.PreparedStatement st;

try
{
    Class.forName("com.esproc.jdbc.InternalDriver");
    con= DriverManager.getConnection("jdbc:esproc:local://");

    st =con.prepareCall("call STUDENT_SCORE_LIST(?)");
    st.setObject(1,"C:/Users/fengm/OneDrive/文档/学生成绩.xlsx");

    st.execute();

    ResultSet rs = st.getResultSet();
}
catch (Exception e)
{
    e.printStackTrace();
}

调用堆栈信息如下:

java.sql.SQLException: 文件 STUDENT_SCORE_LIST 不存在
	at com.esproc.jdbc.InternalStatement.executeJDBC(InternalStatement.java:286)
	at com.esproc.jdbc.InternalStatement$1.run(InternalStatement.java:148)
Caused by: com.scudata.common.RQException: 文件 STUDENT_SCORE_LIST 不存在
	at com.scudata.app.common.AppUtil.readCellSet(AppUtil.java:798)
	at com.scudata.expression.fn.JDBCCall.calculate(JDBCCall.java:70)
	at com.scudata.expression.Expression.calculate(Expression.java:143)
	at com.scudata.expression.fn.Eval.calc(Eval.java:88)
	at com.esproc.jdbc.JDBCUtil.execute(JDBCUtil.java:418)
	at com.esproc.jdbc.InternalStatement.executeJDBC(InternalStatement.java:267)
	... 1 more

集算器v2018这个版本是支持这样调用脚本文件的

from esproc.

RQWangXiaoJun avatar RQWangXiaoJun commented on July 21, 2024

看异常信息跟最新版的jar包不匹配,我看了一下目前的实现应该没这个错误。
请换最新版的集算器的jar包试一下。

from esproc.

FengMingJian avatar FengMingJian commented on July 21, 2024

替换了最新版(20220228版本)的jar包,依旧抛出以下错误信息,望请排除,谢谢

java.sql.SQLException: 文件 STUDENT_SCORE_LIST 不存在
	at com.esproc.jdbc.InternalStatement.executeJDBC(InternalStatement.java:286)
	at com.esproc.jdbc.InternalStatement$1.run(InternalStatement.java:148)
Caused by: com.scudata.common.RQException: 文件 STUDENT_SCORE_LIST 不存在
	at com.scudata.app.common.AppUtil.readCellSet(AppUtil.java:795)
	at com.scudata.expression.fn.JDBCCall.calculate(JDBCCall.java:68)
	at com.scudata.expression.Expression.calculate(Expression.java:143)
	at com.scudata.expression.fn.Eval.calc(Eval.java:88)
	at com.esproc.jdbc.JDBCUtil.execute(JDBCUtil.java:418)
	at com.esproc.jdbc.InternalStatement.executeJDBC(InternalStatement.java:267)
	... 1 more

from esproc.

wunanraq avatar wunanraq commented on July 21, 2024

替换了最新版(20220228版本)的jar包,依旧抛出以下错误信息,望请排除,谢谢

java.sql.SQLException: 文件 STUDENT_SCORE_LIST 不存在
	at com.esproc.jdbc.InternalStatement.executeJDBC(InternalStatement.java:286)
	at com.esproc.jdbc.InternalStatement$1.run(InternalStatement.java:148)
Caused by: com.scudata.common.RQException: 文件 STUDENT_SCORE_LIST 不存在
	at com.scudata.app.common.AppUtil.readCellSet(AppUtil.java:795)
	at com.scudata.expression.fn.JDBCCall.calculate(JDBCCall.java:68)
	at com.scudata.expression.Expression.calculate(Expression.java:143)
	at com.scudata.expression.fn.Eval.calc(Eval.java:88)
	at com.esproc.jdbc.JDBCUtil.execute(JDBCUtil.java:418)
	at com.esproc.jdbc.InternalStatement.executeJDBC(InternalStatement.java:267)
	... 1 more

您好,已经找到了问题,刚刚修复提交了。请更新代码后重试,谢谢!

from esproc.

FengMingJian avatar FengMingJian commented on July 21, 2024

已验证,问题已经修复

from esproc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.