=file("xx.ctx").open().cursor@x(;).skip() 报错 Stream Closed
环境是:代码链接远程集算器。
esproc-bin-20240731.jar
代码集算器配置文件 raqsoftConfig.xml
代码:
public static void main(String[] args) throws ClassNotFoundException, SQLException {
String fileName = “call 游标关闭有 bug”;
Connection con = EsProcUtils.getConnection();
com.esproc.jdbc.InternalCStatement st =
(com.esproc.jdbc.InternalCStatement) con.prepareCall(fileName);
// 执行存储过程
boolean hasResult = st.execute();
EsProcUtils.close(null, con);
}
脚本内容是:
上面使用 @x 自动关闭游标,会报错 Stream Closed。
如果把上面代码拆分写,则不会报错。
报错内容是:
xception in thread “main” java.sql.SQLException: 单元格 [游标关闭有 bug.splx].A3 中有错误
Stream Closed
at com.scudata.server.unit.lIIIIlIlIIllIIII.run(Unknown Source:155)
Caused by: com.scudata.common.RQException: 单元格 [游标关闭有 bug.splx].A3 中有错误
Stream Closed
at com.scudata.dw.Cursor.getData(Unknown Source:1766)
at com.scudata.dw.Cursor.get(Unknown Source:1410)
at com.scudata.dm.cursor.ICursor.fetch(Unknown Source:347)
at com.scudata.dm.cursor.MergeCursor2.$1(Unknown Source:73)
at com.scudata.dm.cursor.MergeCursor2.skipOver(Unknown Source:732)
at com.scudata.dm.cursor.ICursor.skip(Unknown Source:909)
at com.scudata.dm.cursor.ICursor.skip(Unknown Source:898)
at com.scudata.expression.mfn.cursor.Skip.calculate(Unknown Source:20)
at com.scudata.expression.operator.DotOperator.calculate(Unknown Source:86)
at com.scudata.expression.Expression.calculate(Unknown Source:161)
at com.scudata.cellset.datamodel.PgmNormalCell.calculate(Unknown Source:159)
at com.scudata.cellset.datamodel.PgmCellSet.$1(Unknown Source:1959)
at com.scudata.cellset.datamodel.PgmCellSet.execute(Unknown Source:2641)
at com.scudata.cellset.datamodel.PgmCellSet.calculateResult(Unknown Source:2684)
at com.scudata.expression.fn.JDBCCall.calculate(Unknown Source:113)
at com.scudata.expression.Expression.calculate(Unknown Source:161)
at com.scudata.expression.fn.Eval.calc(Unknown Source:168)
at com.scudata.app.common.AppUtil.execute1(AppUtil.java:325)
at com.esproc.jdbc.JDBCUtil.execute(JDBCUtil.java:209)
at com.esproc.jdbc.JDBCUtil.execute(JDBCUtil.java:100)
at com.scudata.server.unit.lIIIIlIlIIllIIII.run(Unknown Source:140)
Caused by: java.io.IOException: Stream Closed
at java.io.RandomAccessFile.seek0(Native Method)
at java.io.RandomAccessFile.seek(RandomAccessFile.java:557)
at com.scudata.dw.ComTable.loadBlock(Unknown Source:391)
at com.scudata.dw.BlockLinkReader.seek(Unknown Source:198)
at com.scudata.dw.BlockLinkReader.readDataBlock(Unknown Source:207)
at com.scudata.dw.BlockLinkReader.readBlockData(Unknown Source:247)
at com.scudata.dw.Cursor.getData(Unknown Source:1609)
… 20 more
脚本文件
bugrar
分开写是指啥?是将 A3 中的 file、open、cursor 分别写到 3 个格子里?
A3 的内容贴全
=file(“2c9a02e1783b5e370178622b6bcb729220240724.ctx”).open().cursor@x(;switchboard_identity_id==“2c9a02e17e53c549017e5627f7417924”).skip() 报错
分开写指:
//=file(“2c9a02e1783b5e370178622b6bcb729220240724.ctx”).open()
=A2.cursor(;switchboard_identity_id==“2c9a02e17e53c549017e5627f7417924”).skip()
=A2.close()
测试脚本上传了,文档有链接
这个 bug 之前修改过,可以更新下 jar 包