MyBatis configuration and Getting Started

  • mybatis history of the development:
    Formerly known as: ibatis: the Apache
    2010 ibatis -> Google colde, Mybatis

  • MyBatis canSimplified operation JDBC, Data persistence.

  • ORM: Object Relational Mapping
    person subject person table

ORM: concept,
- Mybatis is an implementation of the ORM / Hibernate
- ORM developers can target the same operation as the operation of the database table.

Mybatis development program from the steps:
Configure mybatis
conf.xml: Configuration database information and map file to be loaded
table - class
mapping file xxMapper.xml: CRUD label
test class:
session.selectOne ( "SQL query needs of namespace.id", " SQL parameter values ");

Published 41 original articles · won praise 1 · views 557

Guess you like

Origin blog.csdn.net/qq_41620020/article/details/104905450