課程
/后端開(kāi)發(fā)
/Java
/MyBatis-Plus入門
我都把mysql換成8.0了。。。。。。
Error creating bean with name 'userMapper' defined in file
2019-07-10
源自:MyBatis-Plus入門 1-5
正在回答
你的啟動(dòng)類或者配置類,增加@MapperScan("com.mp.dao")這個(gè)注解了嗎?
把@Autowired? 改成@Resource
SperiaX
是這樣,我也遇到了這個(gè)問(wèn)題,但是我直接在@Test標(biāo)簽運(yùn)行select方法,還是可以進(jìn)行數(shù)據(jù)庫(kù)的操作?
祭羽丶琉璃
<dependency> ????<groupId>com.baomidou</groupId> ????<artifactId>mybatis-plus-boot-starter</artifactId> ????<version>2.1.9</version> </dependency> <!--<dependency>--> ????<!--<groupId>com.baomidou</groupId>--> ????<!--<artifactId>mybatis-plus-support</artifactId>--> ????<!--<version>2.1.9</version>--> <!--</dependency>-->
這樣子解決了問(wèn)題
老猿
卡到這里了, 沒(méi)法往下學(xué)了
我也遇到同樣的問(wèn)題了,那個(gè)掃描寫了的,我再檢查看看
三又十二分之四
舉報(bào)
MyBatis-Plus框架入門必學(xué)課程!
2 回答UserMapper
2 回答userMapper問(wèn)題
1 回答掃描不到userMapper的路徑
1 回答UserMapper代碼是在哪里?
1 回答無(wú)法用@SpringBootTest注解,不知道怎么解決
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號(hào)-11 京公網(wǎng)安備11010802030151號(hào)
購(gòu)課補(bǔ)貼聯(lián)系客服咨詢優(yōu)惠詳情
慕課網(wǎng)APP您的移動(dòng)學(xué)習(xí)伙伴
掃描二維碼關(guān)注慕課網(wǎng)微信公眾號(hào)
2019-07-10
你的啟動(dòng)類或者配置類,增加@MapperScan("com.mp.dao")這個(gè)注解了嗎?
2019-07-19
把@Autowired? 改成@Resource
2019-07-12
是這樣,我也遇到了這個(gè)問(wèn)題,但是我直接在@Test標(biāo)簽運(yùn)行select方法,還是可以進(jìn)行數(shù)據(jù)庫(kù)
的操作?
2019-07-12
這樣子解決了問(wèn)題
2019-07-11
卡到這里了, 沒(méi)法往下學(xué)了
2019-07-11
我也遇到同樣的問(wèn)題了,那個(gè)掃描寫了的,我再檢查看看