同样的报表换了个电脑环境,无法打开。

本帖最后由 horsequan 于 2016-6-5 23:18 编辑

麻烦问下同样的模板,换了一个环境,就打不开了,提示Array index out of range: 1794,这个是什么原因导致的呢?
错误代码如下
  1. java.lang.ArrayIndexOutOfBoundsException: Array index out of range: 1794 at com.fr.cache.list.IntList.get(Unknown Source) at com.fr.cache.list.MappedByteBufferList.get(Unknown Source) at com.fr.cache.list.MappedByteBufferTable.getValueAt(Unknown Source) at com.fr.data.impl.DiskCacheDBDataModel.getValueAt(Unknown Source) at com.fr.data.index.AbstractIndexDataModel.getValueAt(Unknown Source) at com.fr.report.cell.cellattr.core.group.FunctionGrouper.current_value(Unknown Source) at com.fr.report.cell.cellattr.core.group.FunctionGrouper.dealGroupMode(Unknown Source) at com.fr.report.cell.cellattr.core.group.FunctionGrouper.group(Unknown Source) at com.fr.report.cell.cellattr.core.group.DSColumn.dealwith_condition_group_sort_select_result(Unknown Source) at com.fr.report.core.A.H.dealWithBEDSColumn(Unknown Source) at com.fr.report.core.A.k.cc_ce_array(Unknown Source) at com.fr.report.core.A.H.A(Unknown Source) at com.fr.report.core.A.H.A(Unknown Source) at com.fr.report.core.A.H.A(Unknown Source) at com.fr.report.core.A.H.resolveColumnRowRange(Unknown Source) at com.fr.report.core.A.u.getVariable(Unknown Source) at com.fr.script.Calculator$NameSpaceChain.getVariable(Unknown Source) at com.fr.script.Calculator.resolveVariableInCE(Unknown Source) at com.fr.stable.script.ColumnRowRange.eval(Unknown Source) at com.fr.script.Calculator.eval(Unknown Source) at com.fr.script.Calculator.evalValue(Unknown Source) at com.fr.script.AbstractFunction.evalExpression(Unknown Source) at com.fr.parser.FunctionCall.eval(Unknown Source) at com.fr.script.Calculator.eval(Unknown Source) at com.fr.stable.script.Expression.eval(Unknown Source) at com.fr.script.Calculator.evalString(Unknown Source) at com.fr.script.Calculator.eval(Unknown Source) at com.fr.script.Calculator.evalValue(Unknown Source) at com.fr.report.core.A.H.dealWithBENormal(Unknown Source) at com.fr.report.core.A.k.cc_ce_array(Unknown Source) at com.fr.report.core.A.H.A(Unknown Source) at com.fr.report.core.A.H.A(Unknown Source) at com.fr.report.core.A.H.A(Unknown Source) at com.fr.report.core.A.H.resolveColumnRowRange(Unknown Source) at com.fr.report.core.A.u.getVariable(Unknown Source) at com.fr.script.Calculator$NameSpaceChain.getVariable(Unknown Source) at com.fr.script.Calculator.resolveVariableInCE(Unknown Source) at com.fr.stable.script.ColumnRowRange.eval(Unknown Source) at com.fr.script.Calculator.eval(Unknown Source) at com.fr.script.Calculator.evalValue(Unknown Source) at com.fr.script.AbstractFunction.evalExpression(Unknown Source) at com.fr.parser.FunctionCall.eval(Unknown Source) at com.fr.script.Calculator.eval(Unknown Source) at com.fr.stable.script.Expression.eval(Unknown Source) at com.fr.script.Calculator.evalString(Unknown Source) at com.fr.script.Calculator.eval(Unknown Source) at com.fr.script.Calculator.evalValue(Unknown Source) at com.fr.report.core.A.H.dealWithBENormal(Unknown Source) at com.fr.report.core.A.k.cc_ce_array(Unknown Source) at com.fr.report.core.A.H.A(Unknown Source) at com.fr.report.core.A.H.A(Unknown Source) at com.fr.report.core.A.H.C(Unknown Source) at com.fr.report.core.A.H.execute4Expand(Unknown Source) at com.fr.report.core.A.H.execute(Unknown Source) at com.fr.report.worksheet.WorkSheet.execute(Unknown Source) at com.fr.report.core.sheet.WorkBookExecutor._execute(Unknown Source) at com.fr.report.core.sheet.WorkBookExecutor.execute(Unknown Source) at com.fr.main.impl.WorkBook.execute(Unknown Source) at com.fr.log.LogUtils.executeAndLogRecord(Unknown Source) at com.fr.stable.AbstractActor.getResultBookFromCacheIfNeed(Unknown Source) at com.fr.main.impl.WorkBookTemplateDelegate.execute(Unknown Source) at com.fr.web.core.ReportSessionIDInfor.calResultWorkBook(Unknown Source) at com.fr.web.core.ReportSessionIDInfor.initBook2Show(Unknown Source) at com.fr.web.core.ReportSessionIDInfor.getWorkBook2Show(Unknown Source) at com.fr.web.core.ReportSessionIDInfor.getReport2Show(Unknown Source) at com.fr.web.core.A.H.A(Unknown Source) at com.fr.web.core.A.IC.actionCMD(Unknown Source) at com.fr.web.core.WebActionsDispatcher.dealForActionCMD(Unknown Source) at com.fr.web.core.WebActionsDispatcher.dealForActionDefaultCmd(Unknown Source) at com.fr.web.core.WebActionsDispatcher.dealForActionCMD(Unknown Source) at com.fr.web.core.A.GC.process(Unknown Source) at com.fr.web.core.ReportDispatcher.dealWithOp(Unknown Source) at com.fr.web.core.ReportDispatcher.dealWeblet(Unknown Source) at com.fr.web.core.ReportDispatcher.dealWithRequest(Unknown Source) at com.fr.web.BaseServlet.doGet(Unknown Source) at javax.servlet.http.HttpServlet.service(HttpServlet.java:622) at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:292) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:502) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:141) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79) at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:616) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:528) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1099) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:672) at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.doRun(AprEndpoint.java:2508) at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:2497) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:745)
复制代码
设计器的日志提示如下
  1. 正常:报表计算中[Name : ptyyhzmaquan.cpt] [Parameter : {__LOCALE__ : zh_CN[java.util.Locale], __STREAMCLOSED__ : [java.lang.String], CMD : parameters_d[java.lang.String], LABELMONTHBS : 月  份:[java.lang.String], LABELYEARBS : 年  份:[java.lang.String], MONTHBS : 05月[java.lang.String], OP : fr_dialog[java.lang.String], REPORTLET : ptyyhzmaquan.cpt[java.lang.String], REPORTNAME : ptyyhzmaquan.cpt[java.lang.String], SESSIONID : 42741[java.lang.String], YEARBS : 2016年[java.lang.String]}][Type : view]  : Array index out of range: 1793
  2. 2016-06-02 16:39:45
  3. 正常:ClassFilePath:file:/D:/Program Files/FineReport_8.0/WebReport/WEB-INF/lib/fr-core-8.0.jar!/com/fr/function
  4. 2016-06-02 16:51:38
  5. 正常:报表计算中[Name : ptyyhzmaquan.cpt] [Parameter : {__LOCALE__ : zh_CN[java.util.Locale], __STREAMCLOSED__ : [java.lang.String], CMD : parameters_d[java.lang.String], LABELMONTHBS : 月  份:[java.lang.String], LABELYEARBS : 年  份:[java.lang.String], MONTHBS : 03月[java.lang.String], OP : fr_dialog[java.lang.String], REPORTLET : ptyyhzmaquan.cpt[java.lang.String], REPORTNAME : ptyyhzmaquan.cpt[java.lang.String], SESSIONID : 73134[java.lang.String], YEARBS : 2016年[java.lang.String]}][Type : view]  : Array index out of range: 1794
复制代码

今天晚上终于找到这个问题的原因了
一直想不通为何某个月的数据会提示数组越界,其实这个问题想想很简单肯定是数据太多,程序定义的太小了导致的。
查询了一下后台每个月汇总的数据 对比了一下 就明白了,查询结果如下

不显示的都是超过了1798行,将数据库查询结果集数据删除了一些,只要你设置的这个数据库查询结果集不超过1798行就不会提示数组越界了,没办法我们的数据就是这么多
只能再换个方式去展现了。毕竟程序我们自己改不了。希望公司能够采纳我的建议将这个数组改到1w,谢谢。


FineReporthorsequan 发布于 2016-6-2 16:34
悬赏:2 F币 + 添加悬赏
提示:增加悬赏、完善问题、追问等操作,可使您的问题被置顶,并向所有关注者发送通知
共4回答
最佳回答
0
horsequan发布于2016-6-2 16:57(编辑于 2023-9-6 09:34)
555
最佳回答
0
星痕发布于2016-6-2 17:20(编辑于 2023-9-6 09:34)
555
最佳回答
0
winnie发布于2016-6-2 17:55(编辑于 2023-9-6 09:34)
555
最佳回答
0
horsequan发布于2016-6-2 18:10(编辑于 2023-9-6 09:34)
555
  • 0关注人数
  • 2260浏览人数
  • 最后回答于:2016-6-2 18:10
    活动推荐 更多
    热门课程 更多
    返回顶部