(mybatis)There is no getter for property named 'isEffective' in 'class java.lang.String
原来代码:
<select id="findSpecialOffer" resultType="com.lizard.back.model.SpecialOffer" parameterType="java.lang.String">
SELECT
taso.id,
taso.product_id as productId ,
taso.table_name as tableName,
taso.start_time_special_off as startTimeSpecialOff,
taso.end_time_special as endTimeSpecial,
taso.create_time as createTime,
taso.operator,
tau.mobile as mobile,
taso.is_effective as isEffective,
taso.type
FROM
`t_admin_special_offer` taso
INNER JOIN t_admin_user tau ON tau.uid = taso.operator
<if test="isEffective!=null">
where taso.is_effective = #{isEffective,jdbcType=VARCHAR}
</if>
</select>
解决方法: 不管你的参数是什么,都要改成"_parameter"
<select id="findSpecialOffer" resultType="com.lizard.back.model.SpecialOffer" parameterType="java.lang.String">
SELECT
taso.id,
taso.product_id as productId ,
taso.table_name as tableName,
taso.start_time_special_off as startTimeSpecialOff,
taso.end_time_special as endTimeSpecial,
taso.create_time as createTime,
taso.operator,
tau.mobile as mobile,
taso.is_effective as isEffective,
taso.type
FROM
`t_admin_special_offer` taso
INNER JOIN t_admin_user tau ON tau.uid = taso.operator
<if test="_parameter !=null and _parameter !=''">
where taso.is_effective = #{isEffective,jdbcType=VARCHAR}
</if>
</select>
(mybatis)There is no getter for property named 'isEffective' in 'class java.lang.String的更多相关文章
- SSM框架报错分析(一)——There is no getter for property named 'XXX' in 'class java.lang.String'
一.发现问题 <select id="queryStudentByNum" resultType="student" parameterType=&quo ...
- mybatis问题: There is no getter for property named 'equipmentId' in 'class java.lang.String'
本文来源于翁舒航的博客,点击即可跳转原文观看!!!(被转载或者拷贝走的内容可能缺失图片.视频等原文的内容) 若网站将链接屏蔽,可直接拷贝原文链接到地址栏跳转观看,原文链接:https://www.cn ...
- Mybatis异常There is no getter for property named 'XXX' in 'class java.lang.String'
1.当入参为 string类型时 (包括java.lang.String.) 我们使用#{xxx}引入参数.会抛异常There is no getter for property named 'XX ...
- Mybatis异常--There is no getter for property named 'XXX' in 'class java.lang.String'
第一种 在service层加@Param(value="ip") void deleteIpsetup(@Param(value="ip")String ip) ...
- mybatis There is no getter for property named 'xx' in 'class java.lang.String
转载自://http://www.cnblogs.com/anee/p/3324140.html 用mybatis查询时,传入一个字符串传参数,且进行判断时,会报 There is no getter ...
- Mybatis问题:There is no getter for property named 'unitId' in 'class java.lang.String'
Mybatis遇到的问题 问题: org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.re ...
- mybatis 异常 There is no getter for property named 'bizId' in 'class java.lang.Long'
mybatis 异常 There is no getter for property named 'bizId' in 'class java.lang.Long' 当使用mybatis进行传参的时候 ...
- mybatis之org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'time' in 'class java.lang.String'
mybatis接口 List<String> getUsedCate(String time); 配置文件 <select id="getUsedCate" pa ...
- Mybatis笔记四:nested exception is org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'id' in 'class java.lang.String'
错误异常:nested exception is org.apache.ibatis.reflection.ReflectionException: There is no getter for pr ...
随机推荐
- Hadoop2.x伪分模式部署
hadoop伪分布模式,只有一个节点,通常用来做测试. 一.环境准备 Linux网络配置已完成,可参见CentOS7网络配置: yum源成功挂载,可参见CentOS7本地yum源挂载: Linux已安 ...
- 关于window的端口查看及tomcat的端口修改问题
1.Windows平台 在windows命令行窗口下执行: 1.查看所有的端口占用情况 C:\>netstat -ano 协议 本地地址 外部地址 ...
- .NET开源工作流RoadFlow-表单设计-下拉列表
下拉列表即<select></select>标签,相关选项与单选按钮组相同: 是否添加空项:即在下拉列表的开头是否添加一个空的选项<option value=" ...
- Android自定义之流式布局
流式布局,好处就是父类布局可以自动的判断子孩子是不是需要换行,什么时候需要换行,可以做到网页版的标签的效果.今天就是简单的做了自定义的流式布局. 具体效果: 原理: 其实很简单,Measure La ...
- unity获取相机视窗口大小
using UnityEngine; using System.Collections; public class CameraView : MonoBehaviour { private Camer ...
- Apache转发到Tomcat
#vi /etc/httpd/conf/httpd.conf 添加下面配置 NameVirtualHost *:80 <VirtualHost *:80>ProxyPreserveHost ...
- 常见WEB开发安全漏洞 原因分析及解决
目 录 1 会话标识未更新 3 1.1 原因 3 1.2 解决 3 2 SQL注入 3 2.1 原因 3 2.2 解决 5 3 XSS跨站脚本编制 5 3.1 原因 5 3.2 解决 5 4 XSRF ...
- 【量产工具修复】U盘插上没反应,格式化提示有写保护
最近在实验室发现师兄留下的U盘,插上电脑后打不开,弹出格式化界面,格式化的时候又提示该u盘“被写保护无法格式化”,于是打算采用量产的方法. 第一步:使用chipgenius监测u盘的芯片制造商和型号 ...
- 关于method not exist:think\db\Query->render错误解决方法
{volist name="Teachers" id="Teachers" key="key"} <tr> <td> ...
- 在同一网关下ping不通其他电脑
最近在做数据库相关的程序,所以想先用ping试下和主机连没连着,但发现虽然两台电脑在同一网关下,但却互相ping不通,后来才发现,原来是防火墙在作怪. Omg!感慨一下!默认的情况下,保守的windo ...