解决方法:

<select id="selectIf" resultType="student">
SELECT id,name,age,score
FROM t_student
WHERE 1=1
<if test="arg0 != null and arg0 !=''">
AND name LIKE '%' #{arg0} '%'
</if>
<if test="arg1>=0">
AND age >= #{arg1}
</if>

</select>

出现异常情况:

如果用where就不用写1=1操作了

Parameter 'name' not found. Available parameters are [arg1, arg0, param1, param2]的更多相关文章

  1. ### Cause: org.apache.ibatis.binding.BindingException: Parameter 'name' not found. Available parameters are [arg1, arg0, param1, param2]

    org.apache.ibatis.exceptions.PersistenceException: ### Error updating database. Cause: org.apache.ib ...

  2. Springboot-001-解决nested exception is org.apache.ibatis.binding.BindingException: Parameter 'env' not found. Available parameters are [arg1, arg0, param1, param2]

    环境:Springboot + Mybatis + MySQL + VUE 场景: 前端发出数据比对请求,在服务后台与数据库交互时,接口提示错误信息如下所示: { "code": ...

  3. SpringBoot整合Mybatis注解版---update出现org.apache.ibatis.binding.BindingException: Parameter 'XXX' not found. Available parameters are [arg1, arg0, param1, param2]

    SpringBoot整合Mybatis注解版---update时出现的问题 问题描述: 1.sql建表语句 DROP TABLE IF EXISTS `department`; CREATE TABL ...

  4. 错误:Parameter '0' not found.Available parameters are [arg1, arg0, param1, param2]的解决方法

    调用的方法: List<Card> temp = cardService.queryRepeat(Type,shop); xml: <select id="queryRep ...

  5. MyBatisSystemException->BindingException: Parameter 'xxx' not found. Available parameters are [arg1, arg0, param1, param2]

    最近在使用Spring boot+mybatis做新的基础框架,结果碰到如下问题: 1 org.mybatis.spring.MyBatisSystemException: nested except ...

  6. org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.binding.BindingException: Parameter 'userId' not found. Available parameters are [arg1, arg0, param1, param2]

    2018-06-27 16:43:45.552  INFO 16932 --- [nio-8081-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : ...

  7. org.apache.ibatis.binding.BindingException: Parameter '0' not found. Available parameters are [arg1, arg0, param1, param2]

    报错信息如下: org.apache.ibatis.binding.BindingException: Parameter '0' not found. Available parameters ar ...

  8. MyBatis报错 Parameter '0' not found. Available parameters are [arg1, arg0, param1, param2]

    修改 <update id="updateStatusById" parameterType="java.lang.Integer"> update ...

  9. 异常:Parameter 'username' not found. Available parameters are [arg1, arg0, param1, param2]

    内容中包含 base64string 图片造成字符过多,拒绝显示

随机推荐

  1. 【Linux-Redhat】新手需要知道的Linux命令

    好像接触运维有一年的时间了吧,查的资料什么的,也算是挺多的了.再加上最近看的<Linux就该这么学>,也算是把自己最近学的东西系统化了一下.今天就来说说,常用的Linux命令有什么,如果你 ...

  2. html5离线记事本

    离线记事本 这是一个笔记应用,不需要联网,也不需要数据库,可以直接把数据储存在本地.方便易用! ^_^ <!DOCTYPE html>  <html>  <head> ...

  3. SSH命令行管理文件

    1.从服务器上下载文件 ssh root@13.111.122.133 2.从服务器上下载文件 scp username@servername:/path/filename /var/www/loca ...

  4. Mysqli扩展类

    Mysqli 扩展是需要php5.0版本以上的支持 主要有以下的3个类 MySQLi类,基本操作 MySQL_STMT类,预处理操作 MySQLi_RESULT类,结果操作 Mysqli的编写有两种方 ...

  5. Mongoose简介

    Mongoose 官网地址:http://mongoosejs.com/   ,Mongoose 为node.js提供了优雅的,针对mongodb的ODM(Object Document Mappin ...

  6. linux shell 之尝试编写 企业级 启动脚本

    企业Shell面试题10:开发企业级MySQL启动脚本 说明: MySQL启动命令为: 1 /bin/sh mysqld_safe --pid-file=$mysqld_pid_file_path 2 ...

  7. CentOS yum 安装 Apache + PHP + MySQL

    # 检查并卸载rpm -qa|grep httpdrpm -e httpdrpm -qa|grep mysqlrpm -e mysqlrpm -qa|grep phprpm -e php # 删除默认 ...

  8. <第一站>人生的第一个博客

    在畅畅的疯狂暗示下(“最好”建个博客),我决定在博客园开通我的博客,在此记入我从3月23起的所学所想.在他的提醒之前,我曾经断断续续的在日记本上,手机备忘录里记录过我的学习情况和心路历程,总的来说,自 ...

  9. zabbix添加对centos系统内存使用率百分比的监控

    1.创建itemConfiguration-->Templates-->Template OS Linux-->items-->create item name:memory ...

  10. linux无法启动httpd服务问题

    httpd 服务启动报错,可能出现的问题比较多,通过查看日志看是什么报错 (tail  200f /etc/httpd/logs/error_log) 1.查看防火墙是不是关闭状态 2.查看80端口是 ...