mybatis返回boolean值时数据库返回null

Posted moonsoft

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了mybatis返回boolean值时数据库返回null相关的知识,希望对你有一定的参考价值。

Servlet.service() for servlet [springDispatcherServlet] in context with path [/ms] threw exception [Request processing failed; nested exception is org.apache.ibatis.binding.BindingException: Mapper method ‘com.ms.dao.AdminDao.checkLoginAdminInfo attempted to return null from a method with a primitive return type (boolean).] with root cause
org.apache.ibatis.binding.BindingException: Mapper method ‘com.ms.dao.AdminDao.checkLoginAdminInfo attempted to return null from a method with a primitive return type (boolean).

 

 

参考:

https://blog.csdn.net/lw1242189467/article/details/80812881

 

https://blog.csdn.net/hbxtw/article/details/10133229


以上是关于mybatis返回boolean值时数据库返回null的主要内容,如果未能解决你的问题,请参考以下文章

Mybatis Update操作返回值问题

MyBatis中Mapper的返回值类型

Mybatis tinyint自动转boolean

mybatis的resulttype为hashmap,java代码怎么写

Mybatis中tinyint数据自动转化为boolean处理

springboot+mybaties返回类型为Map,null值不显示问题