qq_生活终病态_0
2020-02-17 19:06
------------------------------这是异常信息------------------------------
java.lang.NullPointerException
at com.imooc.service.impl.UserServiceImpl.queryUserSimplyInfoById(UserServiceImpl.java:118)
at com.imooc.controller.MyBatisCRUDController.queryUserByIdCustom(MyBatisCRUDController.java:110)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
------------------------------这是xml配置------------------------------
<mapper namespace="com.imooc.mapper.SysUserMapperCustom" >
<!-- resultType就是不需要配置restmap对应属性参数,但是需要字段与数据库字段保持一致 parameterType为传入参数类型-->
<select id="queryUserSimplyInfoById" resultType="com.imooc.pojo.SysUser"
parameterType="java.lang.String" >
select * from sys_user where id = #{id,jdbcType=VARCHAR}
</select>
<sql id="columns">id,username</sql>
</mapper>
at java.lang.reflect.Method.invoke(Method.java:498)
UserServiceImpl.java:118 行空指针
SpringBoot开发常用技术整合
102171 学习 · 508 问题
相似问题