zoukankan      html  css  js  c++  java
  • 个人博客遇到的问题

    1.数据库中type类型为tinyint,默认为0。在数据库中查询条件为type=0时能够正确查询,但是集成到Mybatis中却将所有的数据显示出来了

    解决:Mybatis中的if条件去掉type!='',原来是 type != null and type!=''

     select id, type, createtime, content,title
        from tb_blog_info
         <where>
              <if test="type != null">
                 type=#{type,jdbcType=TINYINT} 
              </if>
         </where>
         ORDER BY createtime DESC limit #{start},#{stop}

     2.上传图片时,jquery中的change方法只触发一次

    解决:算不上解决,记录一下,只要传的文件与上一次的信息不一样就能触发了,如果上传同样的文件,jquery默认不触发change方法。当我们上传同样的文件时,最好重命名一下就可以了。

  • 相关阅读:
    Excel教程(5)
    Excel教程(4)
    Excel教程(3)
    Excel教程(2)
    如何在Excel中少犯二(I)
    for zip
    temp
    study
    eclipse
    shell
  • 原文地址:https://www.cnblogs.com/liter7/p/7750366.html
Copyright © 2011-2022 走看看