zoukankan      html  css  js  c++  java
  • mybatis在.xml中写sql语句是的注意事项

    mybatis在.xml中写sql语句是的注意事项
    用--这个注释 一条SQL语句时候这条SQL语句也会执行,到时候就会报一些莫名其妙的错误
    例如
    org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.type.TypeException: Could not set parameters for mapping: ParameterMapping{property=‘Second_PageHelper’, mode=IN, javaType=class java.lang.Integer, jdbcType=null, numericScale=null, resultMapId=‘null’, jdbcTypeName=‘null’, expression=‘null’}. Cause: org.apache.ibatis.type.TypeException: Error setting non null for parameter #1 with JdbcType null . Try setting a different JdbcType for this parameter or a different configuration property. Cause: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).

    这个是<sql>这个标签中写了俩sql语句的原因
    ————————————————
    版权声明:本文为CSDN博主「fzc3088954783」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
    原文链接:https://blog.csdn.net/fzc3088954783/article/details/105770138

  • 相关阅读:
    MySQl查询语句大全
    并发编程三
    并发编程二
    并发编程
    网络编程
    面向对象高级进阶
    python中的面向对象和面向过程
    为什么还需要学习TypeScript
    Chrome 神器,神奇的技巧
    vue-property-decorator知识梳理
  • 原文地址:https://www.cnblogs.com/fzc521/p/12779851.html
Copyright © 2011-2022 走看看