Mybatis
璀若星辰
Joker Face ------ 杰
展开
-
Mybatis中传参包There is no getter for property named 'XXX' in 'class java.lang.String'
一、发现问题 select num,name,phone from student AND num = #{num} Mybatis查询传入一个字符串传参数,报There is no getter for property named 'num' in 'class java.lang.String'。二、解决问题 select转载 2013-12-16 17:09:41 · 742 阅读 · 0 评论 -
Mybatis各种模糊查询
模糊查询:工作中用到,写三种用法吧 1. sql中字符串拼接 SELECT * FROM tableName WHERE name LIKE CONCAT(CONCAT('%', #{text}), '%'); 2. 使用 ${...} 代替 #{...} SELECT * FROM tableName WHERE name LIKE '%${text}%';转载 2014-01-14 17:44:48 · 658 阅读 · 0 评论