Caused by: org.apache.ibatis.builder.BuilderException: Error evaluating expression ‘dept.name != null and dept.name != ‘’’. Cause: org.apache.ibatis.ognl.OgnlException: source is null for getProperty(null, “name”)
注意了,与书写格式无关,是因为有些时候传入对象dept本来就是空值,导致空指针
解决办法:
加上dept !=null
![在这里插入图片描述](https://i-blog.csdnimg.cn/blog_migrate/f48633296a10bb21780ba702946cf2f9.png)