参数传递错误
我在报表中定义的SQL如下
select * from jy_tmxxb where sqdzt='8' ${has(jg)?(”and jgbh='”+jg+”'”):””}
然后传入了jg参数
但运行的时候就报如下错误
Sourced file: has(jg)?(”and jgbh='”+jg+”'”):”” Token Parsing Error: Lexical error at line 1, column 10. Encountered: "\u201d" (8221), after : ""
Sourced file: has(jg)?(”and jgbh='”+jg+”'”):”” Token Parsing Error: Lexical error at line 1, column 10. Encountered: "\u201d" (8221), after : "": <at unknown location>
at bsh.Interpreter.eval(Interpreter.java:878)
at bsh.Interpreter.eval(Interpreter.java:777)
at bsh.Interpreter.eval(Interpreter.java:1030)
at bsh.Interpreter.eval(Interpreter.java:1020)
at jatools.engine.script.ReportContext.eval(ReportContext.java:273)
at jatools.engine.script.ReportContext.evalTemplate(ReportContext.java:224)
at jatools.data.reader.sql.SqlReader.readStart(SqlReader.java:205)
at jatools.data.reader.sql.SqlReader.getDataset(SqlReader.java:490)
at jatools.data.reader.sql.SqlReader.doRead(SqlReader.java:481)
at jatools.data.reader.AbstractDatasetReader.read(AbstractDatasetReader.java:88)
at jatools.dom.src.DatasetNodeSource.create(DatasetNodeSource.java:130)
at jatools.dom.NodeFactory.createChildNodes(NodeFactory.java:45)
at jatools.dom.ElementBase.getChildElements(ElementBase.java:500)
at jatools.dom.DatasetBasedNode.getLength(DatasetBasedNode.java:396)
at jatools.dom.DatasetBasedNode.getFirstChild(DatasetBasedNode.java:239)
at org.jaxen.dom.DocumentNavigator$1.getFirstNode(DocumentNavigator.java:155)
at org.jaxen.dom.DocumentNavigator$NodeIterator.<init>(DocumentNavigator.java:871)
at org.jaxen.dom.DocumentNavigator$1.<init>(DocumentNavigator.java:157)
at org.jaxen.dom.DocumentNavigator.getChildAxisIterator(DocumentNavigator.java:152)
at org.jaxen.expr.iter.IterableChildAxis.iterator(IterableChildAxis.java:75)
at org.jaxen.expr.DefaultNameStep.evaluate(DefaultNameStep.java:199)
at org.jaxen.expr.DefaultLocationPath.evaluate(DefaultLocationPath.java:140)
at org.jaxen.expr.DefaultXPathExpr.asList(DefaultXPathExpr.java:102)
at org.jaxen.BaseXPath.selectNodesForContext(BaseXPath.java:680)
at org.jaxen.BaseXPath.selectNodes(BaseXPath.java:219)
at jatools.engine.printer.AbstractPrinter.createCursor(AbstractPrinter.java:250)
at jatools.engine.printer.AbstractContainerPrinter.print(AbstractContainerPrinter.java:217)
at jatools.engine.printer.table.TablePrinter.print(TablePrinter.java:67)
at jatools.engine.printer.AbstractContainerPrinter.printChildren(AbstractContainerPrinter.java:150)
at jatools.engine.printer.AbstractContainerPrinter.next(AbstractContainerPrinter.java:298)
at jatools.engine.printer.AbstractContainerPrinter.print(AbstractContainerPrinter.java:233)
at jatools.engine.printer.AbstractContainerPrinter.printChildren(AbstractContainerPrinter.java:150)
at jatools.engine.printer.AbstractContainerPrinter.next(AbstractContainerPrinter.java:298)
at jatools.engine.printer.AbstractContainerPrinter.print(AbstractContainerPrinter.java:233)
at jatools.engine.printer.ReportPrinter.print(ReportPrinter.java:266)
at jatools.engine._Job.generatePage(_Job.java:150)
at jatools.engine._Job.printAsDHTML2(_Job.java:123)
at jatools.engine.ReportJob.printAsDHTML(ReportJob.java:137)
at jatools.tags.ReportTag.writeOut(ReportTag.java:156)
at jatools.tags.ContainerTag.writeOut(ContainerTag.java:78)
at org.apache.jsp.tools.defaultviewer_jsp._jspService(defaultviewer_jsp.java:258)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:679)
at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:461)
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:399)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
at org.apache.jsp.tools.reportviewer_jsp._jspService(reportviewer_jsp.java:52)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at cn.sckj.lis.base.utils.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:70)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:875)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
at java.lang.Thread.run(Thread.java:662)
select * from jy_tmxxb where sqdzt='8'
大家帮帮忙