Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
3.7k views
in Technique[技术] by (71.8m points)

使用maven创建mybatis项目时 报找不到mybatis-config.xml

楼主是PHP刚刚转过来的java 然后 刚刚看了maven的教程,写好的代码后准备测试时确保错
Could not find resource mybatis-config.xml
image.png
下面是代码:
MybatisUtil.java
image.png
Mybatis-config.xml
image.png
测试类
image.png

maven中 资源路径这么写可以不?


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

同PHP转java几年,建议使用mybatis-plus吧,更方便点,不用写xml,可以参考下我的这篇文章:
PHP转JAVA开发30分钟实战攻略


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...