Intellij16 creation of Spring-mybatis project Create (PIT) record, solve the idea under the XML file can not find the problem

Source: Internet
Author: User

Transferred to IntelliJ has been 1 months, the programming efficiency is really much faster than eclipse, and can directly use MAVEN, and then want to write a small project to play, architecture, thinking about everything, not the first time to play the frame, divert to die half a day can be completed, As a result, I never thought, full-time investment (fill) into (pit) spent half a day, and most of it is aimless trial and error, sweat, found out the problem on the Internet can not find the time is really headless flies.

The initial project structure is like this

Everything is ready. Run the test. Boot no problem, when the DAO method is requested, there is no unexpected error. As follows

Org.apache.ibatis.binding.BindingException:Invalid bound statement (not found): Com.fortuneshare.integral.IntegralGradeMapper.findAll

A look at the mistake I thought was yourself mapper.xml and MyBatis interface namespace is not configured to. Look closely but don't see the problem. Multiple recompilation restarts are also not a very handy. Suddenly notice the packet structure of the circled red box in the diagram, and then open idea's project structure to see the source of the modules, as

In idea, if the default package is empty, you merge the structure yourself, and when you create a folder, be sure to look at the project structure. Make sure that the folder structure is not merged.

Intellij16 creation of Spring-mybatis project Create (PIT) record, solve the idea under the XML file can not find the problem

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.