Project: Birt
Bug 147403 [regression][Linux-ws]Preview attached script report throws error.
Reported: 2006-06-15 23:29:36 | Status: closed fixed

Description: Preview attached script report throws error. Steps to reproduce: 1. Open attached report 2. Edit scriptdataset and preview result: 3. Drag the script dataset to layout and preview Expected result: No errors. Actual result: In step3, errors msg displayed as : Data (id = 188): - There are errors evaluating script "row["Num"]". Error.ScriptEvaluationError ( 10 time(s) ) detail : org.eclipse.birt.report.engine.api.EngineException: There are errors evaluating script "row["Num"]". at org.eclipse.birt.report.engine.executor.ExecutionContext.evaluate(ExecutionContext.java:566) at org.eclipse.birt.report.engine.executor.ExecutionContext.evaluate(ExecutionContext.java:528) at org.eclipse.birt.report.engine.executor.DataItemExecutor.execute(DataItemExecutor.java:89) at org.eclipse.birt.report.engine.executor.ReportItemExecutor.execute(ReportItemExecutor.java:139) at org.eclipse.birt.report.engine.executor.ReportItemExecutor.execute(ReportItemExecutor.java:147) at org.eclipse.birt.report.engine.executor.ReportItemExecutor.execute(ReportItemExecutor.java:147) at org.eclipse.birt.report.engine.executor.ReportItemExecutor.execute(ReportItemExecutor.java:147) at org.eclipse.birt.report.engine.executor.ReportItemExecutor.execute(ReportItemExecutor.java:147) at org.eclipse.birt.report.engine.executor.ReportExecutor.execute(ReportExecutor.java:157) at org.eclipse.birt.report.engine.api.impl.RunAndRenderTask.run(RunAndRenderTask.java:176) at org.eclipse.birt.report.service.ReportEngineService.runAndRenderReport(Unknown Source) at org.eclipse.birt.report.service.ReportEngineService.runAndRenderReport(Unknown Source) at org.eclipse.birt.report.service.BirtViewerReportService.runAndRenderReport(Unknown Source) at org.eclipse.birt.report.service.actionhandler.BirtRunAndRenderActionHandler.__execute(Unknown Source) at org.eclipse.birt.report.service.actionhandler.AbstractBaseActionHandler.execute(Unknown Source) at org.eclipse.birt.report.presentation.aggregation.layout.EngineFragment.doService(Unknown Source) at org.eclipse.birt.report.presentation.aggregation.AbstractBaseFragment.service(Unknown Source) at org.eclipse.birt.report.servlet.BirtEngineServlet.__doGet(Unknown Source) at org.eclipse.birt.report.servlet.BaseReportEngineServlet.doGet(Unknown Source) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643) at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2422) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641) at org.eclipse.tomcat.internal.EclipseErrorReportValve.invoke(EclipseErrorReportValve.java:153) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:199) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:828) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:700) at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:584) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683) at java.lang.Thread.run(Thread.java:534) Caused by: org.mozilla.javascript.EvaluatorException: org.eclipse.birt.data.engine.core.DataException: A BIRT exception occurred: Can not convert the value of 10.0 to Integer type.. See next exception for more information. Can not convert the value of 10.0 to Integer type. at org.eclipse.birt.report.engine.data.dte.NativeRowObject.get(NativeRowObject.java:86) at org.mozilla.javascript.ScriptableObject.getProperty(ScriptableObject.java:1263) at org.mozilla.javascript.ScriptRuntime.getObjectElem(ScriptRuntime.java:1301) at org.mozilla.javascript.ScriptRuntime.getObjectElem(ScriptRuntime.java:1283) at org.mozilla.javascript.gen.c77._c0(<inline>:1) at org.mozilla.javascript.gen.c77.call(<inline>) at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:304) at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:2769) at org.mozilla.javascript.gen.c77.call(<inline>) at org.mozilla.javascript.gen.c77.exec(<inline>) at org.eclipse.birt.core.script.ScriptContext.eval(ScriptContext.java:224) at org.eclipse.birt.report.engine.executor.ExecutionContext.evaluate(ExecutionContext.java:559) ... 52 more

Files changed in fix:
core/org.eclipse.birt.core/src/org/eclipse/birt/core/data/DataTypeUtil.java