码迷,mamicode.com
首页 > 其他好文 > 详细

这丫头也的还真清楚,但是跑不通呢,换3.0.3的mybatis也不行

时间:2015-06-11 18:34:21      阅读:120      评论:0      收藏:0      [点我收藏+]

标签:

http://java.dzone.com/articles/ibatis-mybatis-handling-joins

http://mybatis.github.io/spring/mappers.html

If the UserMapper has a corresponding MyBatis XML mapper file in the same classpath location as the mapper interface, it will be parsed automatically by the MapperFactoryBean. There is no need to specify the mapper in a MyBatis configuration file unless the mapper XML files are in a different classpath location. See the SqlSessionFactoryBean‘s configLocation property for more information.

用mybatis-spring的时候找了好就配置文件和mapper文件怎么放,其实放接口同一目录就行,不用担心人家会自动找到。

annotation遇到many的时候说啥也不行,建议不要用。

 

mybatis最重要的就是mapping了,nested select会带来n+1的问题,用nested mapper

这丫头也的还真清楚,但是跑不通呢,换3.0.3的mybatis也不行

标签:

原文地址:http://www.cnblogs.com/jvava/p/4569513.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!