开发者社区> 问答> 正文

点击查看某条sq报错?报错

@wenshao 你好,想跟你请教个问题:

数据库:mysql 5.5

mybatis3.01

druid 0.29

报错信息

我点击查看某条sql
com.alibaba.druid.sql.parser.ParserException: TODO VARIANT #
at com.alibaba.druid.sql.parser.SQLStatementParser.parseStatementList(SQLStatementParser.java:224)
at com.alibaba.druid.sql.parser.SQLStatementParser.parseStatementList(SQLStatementParser.java:68)
at com.alibaba.druid.sql.SQLUtils.parseStatements(SQLUtils.java:232)
at com.alibaba.druid.stat.DruidStatService.getSqlStat(DruidStatService.java:271)
at com.alibaba.druid.stat.DruidStatService.service(DruidStatService.java:126)
at com.alibaba.druid.support.http.StatViewServlet.service(StatViewServlet.java:245)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:304)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:240)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:164)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:498)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:394)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:243)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:188)
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:302)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)

at java.lang.Thread.run(Thread.java:722)

以下是完整的sql

 <select id="getProCount" resultType="java.lang.Integer" parameterType="java.lang.String">
        SELECT COUNT(p.id) FROM TB_PRO p
        INNER JOIN   TB_Db  b ON b.id =p.dbid         
        WHERE p.index_status='0' AND p.sc=#{value}#
</select>


展开
收起
爱吃鱼的程序员 2020-06-22 22:14:44 350 0
1 条回答
写回答
取消 提交回答
  • https://developer.aliyun.com/profile/5yerqm5bn5yqg?spm=a2c6h.12873639.0.0.6eae304abcjaIB

    你升级到0.2.10试试看把完整的SQL帖出来吧

    以下是完整的sql

     <selectid="getProCount"resultType="java.lang.Integer"parameterType="java.lang.String">
          SELECTCOUNT(p.id)FROMTB_PROp
          INNERJOIN  TB_Db bONb.id=p.dbid      
          WHEREp.index_status='0'ANDp.sc=#{value}#
    </select>

    <selectid="getProCount"resultType="java.lang.Integer"parameterType="java.lang.String">
          SELECTCOUNT(p.id)FROMTB_PROp
          INNERJOIN  TB_Db bONb.id=p.dbid      
          WHEREp.index_status='0'ANDp.sc=#{value}
    </select>


    2020-06-22 22:15:00
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
低代码开发师(初级)实战教程 立即下载
冬季实战营第三期:MySQL数据库进阶实战 立即下载
阿里巴巴DevOps 最佳实践手册 立即下载