`

TableTag Problem: javax.servlet.jsp.el.ELException

阅读更多
错误为:
javax.servlet.jsp.JspException: TableTag Problem: javax.servlet.jsp.el.ELException: The "." operator was supplied with an index value of type "java.lang.String" to be applied to a List or array, but that value cannot be converted to an integer.
	at org.apache.commons.el.Logger.logError(Logger.java:481)
	at org.apache.commons.el.Logger.logError(Logger.java:498)
	at org.apache.commons.el.Logger.logError(Logger.java:566)
	at org.apache.commons.el.ArraySuffix.evaluate(ArraySuffix.java:227)
	at org.apache.commons.el.ComplexValue.evaluate(ComplexValue.java:145)
	at org.apache.commons.el.ExpressionEvaluatorImpl.evaluate(ExpressionEvaluatorImpl.java:263)
	at org.apache.commons.el.ExpressionEvaluatorImpl.evaluate(ExpressionEvaluatorImpl.java:190)
	at org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(PageContextImpl.java:924)
	at org.apache.jsp.home.sp.operationOrder.spServiceMgrInfoList_jsp._jspx_meth_sit_005fcolumn_005f0(spServiceMgrInfoList_jsp.java:739)
	at org.apache.jsp.home.sp.operationOrder.spServiceMgrInfoList_jsp._jspx_meth_sit_005frow_005f0(spServiceMgrInfoList_jsp.java:657)
	at org.apache.jsp.home.sp.operationOrder.spServiceMgrInfoList_jsp._jspx_meth_sit_005ftable_005f0(spServiceMgrInfoList_jsp.java:621)
	at org.apache.jsp.home.sp.operationOrder.spServiceMgrInfoList_jsp._jspx_meth_sit_005fpagestyle_005f0(spServiceMgrInfoList_jsp.java:533)
	at org.apache.jsp.home.sp.operationOrder.spServiceMgrInfoList_jsp._jspService(spServiceMgrInfoList_jsp.java:219)
	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.struts2.dispatcher.ServletDispatcherResult.doExecute(ServletDispatcherResult.java:139)
	at org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:178)
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455)
	at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221)
	at org.extremecomponents.table.tag.TableTag.doCatch(TableTag.java:488)
	at org.apache.jsp.home.sp.operationOrder.spServiceMgrInfoList_jsp._jspx_meth_sit_005ftable_005f0(spServiceMgrInfoList_jsp.java:636)
	at org.apache.jsp.home.sp.operationOrder.spServiceMgrInfoList_jsp._jspx_meth_sit_005fpagestyle_005f0(spServiceMgrInfoList_jsp.java:533)
	at org.apache.jsp.home.sp.operationOrder.spServiceMgrInfoList_jsp._jspService(spServiceMgrInfoList_jsp.java:219)
	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.struts2.dispatcher.ServletDispatcherResult.doExecute(ServletDispatcherResult.java:139)
	at org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:178)
	at com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:127)
	at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
	at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:1)
	at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455)
	at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221)
	at org.apache.struts2.interceptor.ProfilingActivationInterceptor.intercept(ProfilingActivationInterceptor.java:107)
	at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:224)
	at com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionInvocation.java:1)
	at com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack.java:455)
	at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:221)
	at org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:206)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
	at org.apache.struts2.dispatcher.ActionContextCleanUp.doFilter(ActionContextCleanUp.java:99)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
	at org.extremecomponents.table.filter.AbstractExportFilter.doFilter(AbstractExportFilter.java:49)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:265)
	at org.acegisecurity.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:107)
	at org.acegisecurity.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:72)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
	at org.acegisecurity.ui.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:166)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
	at org.acegisecurity.providers.anonymous.AnonymousProcessingFilter.doFilter(AnonymousProcessingFilter.java:125)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
	at org.acegisecurity.ui.logout.LogoutFilter.doFilter(LogoutFilter.java:110)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
	at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:142)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
	at com.sailing.framework.components.security.acegi.DBUserGroupFilterHandler.doFilter(DBUserGroupFilterHandler.java:133)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
	at org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:173)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
	at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:271)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
	at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:249)
	at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
	at org.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:149)
	at org.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:98)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:96)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:75)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
	at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:75)
	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:595)
02:54:07,703 ERROR [/webapp/sp_operationSpeakOrder/findSpServiceInfo.action] TableTag Problem: javax.servlet.jsp.el.ELException: The "." operator was supplied with an index value of type "java.lang.String" to be applied to a List or array, but that value cannot be converted to an integer.



页面为:
<sit:table items="spServiceList" var="spService" filterable="false"
action="" rowsDisplayed='10'>
<sit:row>
<sit:column width="10%" property="feeName" title="资费名称" sortable="false"
style="text-align: center" headerStyle="text-align: center">
<font color="#FF0000" title="${spService[0].feeName}">
            ${spService[0].feeName}
</font>
</sit:column>
<sit:column width="10%" property="spId" title="企业代码" sortable="true"
            style="text-align: center" headerStyle="text-align: center" >
${spService[1].spId }
</sit:column>
<sit:column width="10%" property="busiTypeName" title="业务类型名称" sortable="true"
            style="text-align: center" headerStyle="text-align: center" >
${spService[1].busiTypeName }
</sit:column>
<sit:column width="15%" property="checkbox" title="操作" sortable="false" viewsAllowed="html"
style="text-align: center" headerStyle="text-align: center" filterable="false">
<!-- 修改  -->
<sit:perm perms="urap_app.editbutton">
    <a style='cursor:hand'  onclick='toPage("edit","${spService[1].spServiceId}")'>
<font color="#ff0000">[修改]</font>
</a>
</sit:perm>
<!-- 逻辑删除  -->
<sit:perm perms="urap_app.delbutton">
<a style='cursor:hand'  onclick='remove("remove","${spService[1].spServiceId}")'>
<font color="#ff0000">[删除]</font>
</a>
</sit:perm>
</sit:column>
</sit:row>
  </sit:table>

使用的架构为struts2+springs+hiberate 。出错是当我想在列表页面中显示数据时报这个错误。我是在action中将查询结果放入List并传回jsp页面中,然后在页面中使用el表达式取每一个元素的数据。
起初遇到这个错误时对流程中的每个步骤进行仔细的检查,查找的资料也没有能够解决,最后在调试的时候才发现,是犯了一个很低级的错误,原因是我查询出来的数据是从多个表中查出的结果,而结果是一个Object,就是说取值的时候应该是像上面所写的一样来取了。而不能直接使用XXList.属性来取值了。
分享到:
评论
1 楼 liusping 2010-07-24  
 

相关推荐

    javax.servlet-3.0.0.v201112011016-API文档-中文版.zip

    赠送jar包:javax.servlet-3.0.0.v201112011016.jar; 赠送原API文档:javax.servlet-3.0.0.v201112011016-javadoc.jar; 赠送源代码:javax.servlet-3.0.0.v201112011016-sources.jar; 赠送Maven依赖信息文件:...

    javax.servlet jar包---解决找不到javax.servlet.*等问题

    - 在传统的Java Web项目中,通常将`javax.servlet.jar`和`javax.servlet.jsp.jar`添加到项目的类路径中,这可以通过在`WEB-INF/lib`目录下放置这两个jar包实现。 - 使用Maven或Gradle等构建工具时,可以在pom.xml...

    javax.servlet-3.0.0.v201112011016-API文档-中英对照版.zip

    赠送jar包:javax.servlet-3.0.0.v201112011016.jar; 赠送原API文档:javax.servlet-3.0.0.v201112011016-javadoc.jar; 赠送源代码:javax.servlet-3.0.0.v201112011016-sources.jar; 赠送Maven依赖信息文件:...

    javax.servlet-api-3.1.0.jar中文文档.zip

    javax.servlet-api-***.jar中文文档.zip,java,javax.servlet-api-***.jar,javax.servlet,javax.servlet-api,***,jar包,Maven,第三方jar包,组件,开源组件,第三方组件,Gradle,javax,servlet,api,中文API文档,手册,开发...

    javax.servlet-api-4.0.1-API文档-中英对照版.zip

    赠送jar包:javax.servlet-api-4.0.1.jar; 赠送原API文档:javax.servlet-api-4.0.1-javadoc.jar; 赠送源代码:javax.servlet-api-4.0.1-sources.jar; 赠送Maven依赖信息文件:javax.servlet-api-4.0.1.pom; ...

    javax.servlet-api-4.0.1.jar中文文档.zip

    javax.servlet-api-***.jar中文文档.zip,java,javax.servlet-api-***.jar,javax.servlet,javax.servlet-api,***,jar包,Maven,第三方jar包,组件,开源组件,第三方组件,Gradle,javax,servlet,api,中文API文档,手册,开发...

    javax.servlet-api-4.0.0-API文档-中文版.zip

    赠送jar包:javax.servlet-api-4.0.0.jar; 赠送原API文档:javax.servlet-api-4.0.0-javadoc.jar; 赠送源代码:javax.servlet-api-4.0.0-sources.jar; 赠送Maven依赖信息文件:javax.servlet-api-4.0.0.pom; ...

    javax.servlet-api-3.0.1.jar中文文档.zip

    javax.servlet-api-***.jar中文文档.zip,java,javax.servlet-api-***.jar,javax.servlet,javax.servlet-api,***,jar包,Maven,第三方jar包,组件,开源组件,第三方组件,Gradle,javax,servlet,api,中文API文档,手册,开发...

    javax.servlet.jar下载

    Files contained in javax.servlet.jar: META-INF/MANIFEST.MF javax/servlet/http/LocalStrings.properties javax.servlet.http.HttpSessionBindingListener.class javax.servlet....

    Java web常用包javax.servlet.jsp.jstl-1.2.1.zip

    在Java Web开发中,`javax.servlet.jsp.jstl`是一个重要的库,全称为JavaServer Pages Standard Tag Library,即JSTL(JavaServer Pages 标准标签库)。这个库提供了用于增强JSP页面功能的一系列标准标签,使得...

    javax.servlet.jar与javax.servlet.jsp.jar

    在Java Web开发中,`javax.servlet.jar`和`javax.servlet.jsp.jar`是两个非常重要的库文件,它们分别提供了Servlet和JSP(JavaServer Pages)的核心API。这两个库是开发基于Java的Web应用程序不可或缺的部分,特别是...

    javax.servlet-api-3.1.0.jar

    在Java Web开发中,`javax.servlet-api-3.1.0.jar`是一个至关重要的组件,它代表了Servlet API的3.1.0版本,是实现服务器端动态网页处理的核心库。Servlet API是Java EE规范的一部分,由Java Community Process (JCP...

    javax.servlet-api-3.1.0.jar javax.el-api-2.2.4.jar javax.el-2.2.4.jar

    在IT行业中,尤其是在Java Web开发领域,`javax.servlet-api`和`javax.el`库是至关重要的组件。这些库主要用于实现Servlet规范和表达式语言(EL)功能,它们为开发人员提供了与服务器交互以及处理HTTP请求的能力。...

    javax.transaction-api-1.2-API文档-中文版.zip

    赠送jar包:javax.transaction-api-1.2.jar; 赠送原API文档:javax.transaction-api-1.2-javadoc.jar; 赠送源代码:javax.transaction-api-1.2-sources.jar; 赠送Maven依赖信息文件:javax.transaction-api-1.2....

    javax.annotation-api-1.3.2-API文档-中文版.zip

    赠送jar包:javax.annotation-api-1.3.2.jar; 赠送原API文档:javax.annotation-api-1.3.2-javadoc.jar; 赠送源代码:javax.annotation-api-1.3.2-sources.jar; 赠送Maven依赖信息文件:javax.annotation-api-...

    javax.servlet---jsp-api jar包

    `javax.servlet` 和 `jsp-api` 是Java服务器端编程的重要组成部分,主要用于构建动态Web应用程序。这两个API是Java Servlet和JavaServer Pages(JSP)技术的核心接口和类库,由Java Community Process (JCP)制定并由...

    javax.servlet-api-4.0.0-API文档-中英对照版.zip

    赠送jar包:javax.servlet-api-4.0.0.jar; 赠送原API文档:javax.servlet-api-4.0.0-javadoc.jar; 赠送源代码:javax.servlet-api-4.0.0-sources.jar; 赠送Maven依赖信息文件:javax.servlet-api-4.0.0.pom; ...

    javax.annotation-api-1.2-API文档-中文版.zip

    赠送jar包:javax.annotation-api-1.2.jar; 赠送原API文档:javax.annotation-api-1.2-javadoc.jar; 赠送源代码:javax.annotation-api-1.2-sources.jar; 赠送Maven依赖信息文件:javax.annotation-api-1.2.pom;...

    javax.servlet.jar包下载

    在Java编程环境中,`javax.servlet.jar` 是一个非常重要的库,它包含了Servlet和JSP(JavaServer Pages)的核心API,是开发Web应用程序的基础组件。这个包由Java EE(Enterprise Edition)标准提供,允许开发者创建...

    javax.servlet.jsp.tagext源码

    在Java服务器页面(JSP)技术中,`javax.servlet.jsp.tagext`包是核心组件之一,它提供了用于创建自定义标签库(Tag Libraries)的接口和类。自定义标签是JSP的一种强大特性,允许开发者将复杂的逻辑封装到可重用的...

Global site tag (gtag.js) - Google Analytics