当前位置:网站首页>Unsatisfied dependency expressed through field ‘baseMapper‘; nested exceptio
Unsatisfied dependency expressed through field ‘baseMapper‘; nested exceptio
2022-06-26 06:12:00 【Oh No 发量又少了】
这个报错主要是在我是用mybatis-plus的时候遇到的,出现这个报错的原因主要有以下两点:
- 导入的依赖的问题:
注意在使用spring boot整合mybatis-plus时导入的是如下依赖
<dependency>
<groupId>io.github.Caratacus</groupId>
<artifactId>mybatis-plus-boot-starter</artifactId>
<version>1.0.9</version>
而不是:
<dependency>-->
<groupId>com.suyeer</groupId>-->
<artifactId>mybatis-plus</artifactId>-->
<version>3.2.0.6</version>-->
</dependency>-->
- 注解问题
在mapper文件中的类中加入@Mapper注解
@Mapper
public interface UserMapper extends BaseMapper<Users> {
}
service接口实现类中加入@Service注解
@Service
public class UserServiceImpl extends ServiceImpl<UserMapper, Users> implements UserService {
}
边栏推荐
- Print bit information of numbers
- Interface oriented programming
- Implementation of third-party wechat authorized login for applet
- 302. minimum rectangular BFS with all black pixels
- Summary of JVM interview focus (II) -- garbage collector (GC) and memory allocation strategy
- canal部署、原理和使用介绍
- Multi thread synchronous downloading of network pictures
- Web components series (10) -- realize the basic layout of mycard
- Transformer中的Self-Attention以及Multi-Head Self-Attention(MSA)
- Mysql-10 (key)
猜你喜欢

ByteDance starts the employee's sudden wealth plan and buys back options with a large amount of money. Some people can earn up to 175%

Library management system

Vs2022 offline installation package download and activation

如何设计好的技术方案

Keepalived to achieve high service availability

Record how to modify the control across threads

PyTorch使用多GPU并行训练及其原理和注意事项

【Spark】Spark SQL 字段血缘如何实现

Message queue - message transaction management comparison

Understanding of nil in go language
随机推荐
Install pyinstaller
SSH keygen specifies the path
PyTorch使用多GPU并行训练及其原理和注意事项
Tortoise and rabbit race example
Keepalived to achieve high service availability
MySQL 索引底层原理
"= =" difference from "equals"
去哪儿网BI平台建设演进史
Five solutions across domains
Comparison between Prometheus and ZABBIX
[intra group questions semester summary] some reference questions for beginners
Younger sister Juan takes you to learn JDBC -- two days' Sprint Day2
Efk Upgrade to clickhouse log Storage Reality
How to select and build a real-time data warehouse scheme
工作积累——Web请求中使用ThreadLocal遇见的问题
numpy.tile()
Easy to understand from the IDE, and then talk about the applet IDE
numpy.exp()
如何设计好的技术方案
Logstash - logstash sends an alarm email to email