1.application.yml文件配置
mybatis: mapper-locations: classpath:mapper/*.xml
2.创建接口
@Mapper和scan二选一
3.创建mapper配置文件
接口和mapper文件位置如下
4.调用
1.application.yml文件配置
mybatis: mapper-locations: classpath:mapper/*.xml
2.创建接口
@Mapper和scan二选一
3.创建mapper配置文件
接口和mapper文件位置如下
4.调用